When I try to run a Create
operation with the trailblazer gem, I get this error:
NoMethodError: undefined method `has_key?' for nil:NilClass
When I try to run a Create
operation with the trailblazer gem, I get this error:
NoMethodError: undefined method `has_key?' for nil:NilClass
Copyright © 2021 Jogjafile Inc.
The problem was I wasn't including the name of the model as the root key for the hash being passed to the create operation. That is, I was calling it like this:
when I should have been passing: