Rails 3.2 and 'can't convert nil into Hash' #54

dreamwieber opened this Issue Apr 7, 2012 · 2 comments

2 participants



I'm getting a 'can't convert nil into Hash' error on my link_to_add_association line, in a Rails 3.2 app.

Here's the top of the stack trace where the error is occurring:

cocoon (1.0.18) lib/cocoon/view_helpers.rb:39:in merge'
cocoon (1.0.18) lib/cocoon/view_helpers.rb:39:in
block in render_association'

link_to_remove_association works fine in the partial, and the partial for my association renders fine, but everything blows up when I try to use link_to_add_association.

Here's what the form looks like: https://gist.github.com/2332370


Yes this error was just fixed in #53. Updating to the latest version should fix this.


Incredible timing. My Saturday just got 10x's better. Thanks!

@dreamwieber dreamwieber closed this Apr 7, 2012
@nathanvda nathanvda added a commit that referenced this issue Apr 8, 2012
@nathanvda Make sure that we will not regress: when not passing locals to the pa…
…rtial, it should still work. This was reported in #54, but first fixed in #53.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment