getUser()->passwordSecurity) { return true; } return ! $this->getUser()->passwordSecurity->google2fa_enable || ! $this->isEnabled() || $this->noUserIsAuthenticated() || $this->twoFactorAuthStillValid(); } /** * @return mixed * @throws \PragmaRX\Google2FALaravel\Exceptions\InvalidSecretKey */ protected function getGoogle2FASecretKey() { $secret = $this->getUser()->passwordSecurity->{$this->config('otp_secret_column')}; if (is_null($secret) || empty($secret)) { throw new InvalidSecretKey('Secret key cannot be empty.'); } return $secret; } }