Skip to content

Commit ddce44f

Browse files
committed
Fix that Redmine::Twofa::Base raises ArgumentError in development mode (#1237, #33925).
git-svn-id: http://svn.redmine.org/redmine/trunk@19995 e93f8b46-1217-0410-a6f0-8f06a7374b81
1 parent 03aebc3 commit ddce44f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/redmine/twofa/base.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def confirm_pairing!(code)
5353
end
5454

5555
def deliver_twofa_paired
56-
Mailer.security_notification(
56+
::Mailer.security_notification(
5757
@user,
5858
User.current,
5959
{
@@ -82,7 +82,7 @@ def destroy_pairing_without_verify!
8282
end
8383

8484
def deliver_twofa_unpaired
85-
Mailer.security_notification(
85+
::Mailer.security_notification(
8686
@user,
8787
User.current,
8888
{
@@ -114,7 +114,7 @@ def verify_backup_code!(code)
114114
Token.where(user_id: @user.id).find_token('twofa_backup_code', code).try(:delete)
115115
# make sure the user using the backup code is the same it's been issued to
116116
return false unless @user.present? && @user == user_from_code
117-
Mailer.security_notification(
117+
::Mailer.security_notification(
118118
@user,
119119
User.current,
120120
{
@@ -135,7 +135,7 @@ def init_backup_codes!
135135
token.update_columns value: Redmine::Utils.random_hex(6)
136136
tokens << token
137137
end
138-
Mailer.security_notification(
138+
::Mailer.security_notification(
139139
@user,
140140
User.current,
141141
{

0 commit comments

Comments
 (0)