Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Devise authentication. undefined method 'authenticate_member!'

I am trying to use:

before_filter :authenticate_member!
before_filter :authenticate_user!

current_member
current_user

in my controller (not at the same time, of course). None of these names could be found. I have installed Devise according to manual: https://github.com/plataformatec/devise

Restarting server after changing the line does not help.

like image 971
Paul Avatar asked Dec 12 '22 03:12

Paul


1 Answers

Ugly Rails defaults! If the user model's name is Restuser then the calls should be:

before_filter :authenticate_restuser!

and

current_restuser
like image 98
Paul Avatar answered Apr 26 '23 06:04

Paul