These are chat archives for edbirmingham/network

Jun 2016
Jun 29 2016 00:04
A few questions to anyone. I'm currently working on recording users when they create new records and trying to accomplish this using Rails concerns. After some research, it seems that the "concern" should be applied to my controllers and that it should use the Devise helper method current_user to pass the current logged in user to the model being created. Is this the correct way to handle this when it comes to separation of concerns? @anthonycrumley @errinlarsen
Anthony Crumley
Jun 29 2016 13:06
@saabdoli Let's do it the easy way and set the user_id attribute in the [model]_params method in each controller.
Anthony Crumley
Jun 29 2016 13:21
@saabdoli Actually it should probably just set it in the create action rather than the _params method because we are just recording the creator.