Skip to content
Snippets Groups Projects
Commit 2f45d3bc authored by Rémy Coutable's avatar Rémy Coutable
Browse files

API: Memoize the current_user so that the sudo can work properly


The issue was arising when `#current_user` was called a second time
after a user was impersonated: the `User#is_admin?` check would be
performed on it and it would fail.

Signed-off-by: default avatarRémy Coutable <remy@rymai.me>
parent 0f6964a3
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment