Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Always return hash error #21

Open
arturictus opened this issue Jul 14, 2016 · 0 comments
Open

Always return hash error #21

arturictus opened this issue Jul 14, 2016 · 0 comments

Comments

@arturictus
Copy link
Owner

We should ensure that the middleware always return a hash.

we could raise an error if the middleware returns something different than a hash.
example:

class Mapper < HashMap::Base
  transforms_output  ->(o) { o.compact }, ->(o){ logger.info(o.inspect) }
  property :name
end

That will return true instead of a hash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant