switch_user
switch_user copied to clipboard
Generator template has old config.controller_guard
In new version config.controller_guard's lambda can use up to 4 arguments, but template contains only 2. I need the controller, and spent 3 hours to found it.
@ukolovda - what was the argument list you ended up using?
@ckk-scratch , this: config.controller_guard = lambda { |current_user, request, original_user, controller| controller.admin_user_signed_in? }