Skip to content

Commit 9ca8128

Browse files
committed
refactor by reusing injected method
1 parent 3b7f096 commit 9ca8128

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/controllers/sudo_rails/application_controller.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ class ApplicationController < ActionController::Base
44

55
def confirm
66
if SudoRails.confirm?(self, params[:password])
7-
session[:sudo_session] = Time.zone.now.to_s
7+
extend_sudo_session!
88
else
99
flash[:alert] = I18n.t('sudo_rails.invalid_pass', locale: params[:locale])
1010
end

0 commit comments

Comments
 (0)