diff options
author | Andrew Davis <andrew.affinity@gmail.com> | 2021-04-14 01:17:51 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-14 01:17:51 +0300 |
commit | beb2699903a8bf92411dcf11945161d518ad6044 (patch) | |
tree | 2c4d1dca01168fe8fad769106240d8345e30bf68 /plugins/Tour/Engagement | |
parent | 4ac51607847c83e93fb2752484458b0040e4ed0c (diff) |
17352 include a warning to users about to turn on require 2fa (#17400)
* 17352 require user to set up 2fa before being able to turn on 'require 2fa'
* 17352 disable instead of hiding 'require 2fa' setting if user isnt using 2fa
Diffstat (limited to 'plugins/Tour/Engagement')
-rw-r--r-- | plugins/Tour/Engagement/ChallengeSetupTwoFa.php | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/plugins/Tour/Engagement/ChallengeSetupTwoFa.php b/plugins/Tour/Engagement/ChallengeSetupTwoFa.php index dc5fa1c65c..9542fc8633 100644 --- a/plugins/Tour/Engagement/ChallengeSetupTwoFa.php +++ b/plugins/Tour/Engagement/ChallengeSetupTwoFa.php @@ -8,7 +8,6 @@ */ namespace Piwik\Plugins\Tour\Engagement; -use Piwik\Container\StaticContainer; use Piwik\Piwik; use Piwik\Plugins\TwoFactorAuth\TwoFactorAuthentication; @@ -31,8 +30,7 @@ class ChallengeSetupTwoFa extends Challenge public function isCompleted() { - $twoFa = StaticContainer::get(TwoFactorAuthentication::class); - return $twoFa->isUserUsingTwoFactorAuthentication(Piwik::getCurrentUserLogin()); + return TwoFactorAuthentication::isUserUsingTwoFactorAuthentication(Piwik::getCurrentUserLogin()); } public function getUrl() |