We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b20c981 commit 81db87fCopy full SHA for 81db87f
lib/redmine_sudo/patches/user_patch.rb
@@ -53,11 +53,10 @@ def deliver_security_notification
53
54
# admin? has been replaced with sudoer?
55
def must_activate_twofa?
56
- return false if twofa_active?
+ rc = super
57
+ return rc if rc
58
- return true if Setting.twofa_required?
59
- return true if Setting.twofa_required_for_administrators? && sudoer?
60
- return true if Setting.twofa_optional? && groups.any?(&:twofa_required?)
+ !twofa_active? && Setting.twofa_required_for_administrators? && sudoer?
61
end
62
63
0 commit comments