devise_masquerade icon indicating copy to clipboard operation
devise_masquerade copied to clipboard

Why `back` method needs authorization?

Open lcjury opened this issue 1 year ago • 1 comments

I want to allow admins to masquerade other users, because of this, I override the masquerade_authorized? method with something like:

def masquerade_authorized?
  admin?
end

The "back_masquerade_path" also uses masquerade_authorized?; since I'm masquerading as a non-admin user, I cannot return to my previous user.

I'm doing something wrong?

lcjury avatar Jul 10 '23 02:07 lcjury