Lisa Klein wrote:
> book.user_id = @user.id
>
> Is this the way it's supposed to be done?  I know that it's preferred
> to interact with dependent resources through their associations. So
> adding the user_id manually seems a bit clunky to me.  But I'm not
>   

Do

book.user = @user

instead then (ultimately it's the same thing obviously).



--~--~---------~--~----~------------~-------~--~----~
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