I have a table with only id, created_at and updated_at, so the form I get rendered looks like this:
As all of the fields are automatically set on creation, I don't have any field to fill manually.
Then, when I submit to create a new record, in line 32 of model_controller.rb, the variable args is set to nil, so, in line 34 I get a undefined method `each' for nil:NilClass error.
It can be fixed just by replacing line 32 with:
args = params[@klass.underscore_name] || []
I haven't submitted any PR as I don't have enough time and Upmin's codebase knowledge to write proper tests to demonstrate the case.
I have a table with only
id
,created_at
andupdated_at
, so the form I get rendered looks like this:As all of the fields are automatically set on creation, I don't have any field to fill manually.
Then, when I submit to create a new record, in line 32 of
model_controller.rb
, the variableargs
is set tonil
, so, in line 34 I get a undefined method `each' for nil:NilClass error.It can be fixed just by replacing line 32 with:
I haven't submitted any PR as I don't have enough time and Upmin's codebase knowledge to write proper tests to demonstrate the case.
I hope this issue is helpful enough.
Thanks.