Commit e67af5d5 authored by Peter Hegman's avatar Peter Hegman Committed by Nick Thomas

Fix the color of the unlock user success alert

parent f67a53a5
...@@ -148,7 +148,7 @@ class Admin::UsersController < Admin::ApplicationController ...@@ -148,7 +148,7 @@ class Admin::UsersController < Admin::ApplicationController
def unlock def unlock
if update_user { |user| user.unlock_access! } if update_user { |user| user.unlock_access! }
redirect_back_or_admin_user(alert: _("Successfully unlocked")) redirect_back_or_admin_user(notice: _("Successfully unlocked"))
else else
redirect_back_or_admin_user(alert: _("Error occurred. User was not unlocked")) redirect_back_or_admin_user(alert: _("Error occurred. User was not unlocked"))
end end
......
...@@ -416,6 +416,7 @@ RSpec.describe Admin::UsersController do ...@@ -416,6 +416,7 @@ RSpec.describe Admin::UsersController do
put :unlock, params: { id: user.username } put :unlock, params: { id: user.username }
user.reload user.reload
expect(user.access_locked?).to be_falsey expect(user.access_locked?).to be_falsey
expect(flash[:notice]).to eq _('Successfully unlocked')
end end
end end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment