I've been working through the Depot application to get back into Rails
after a few years doing other things. While I was looking at some
functional tests earlier I started thinking about this:

put :update, id: @user.to_param, user: @input_attributes

why doesn't the "id: @..." part throw an exception? id: isn't a
symbol. Is this some sort of alternative method of declaring a hash?
Is it a method call?

It works, which is great, but I'd love to know why.

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to