diff options
Diffstat (limited to 'lib/public/Authentication/TwoFactorAuth/TwoFactorProviderForUserEnabled.php')
-rw-r--r-- | lib/public/Authentication/TwoFactorAuth/TwoFactorProviderForUserEnabled.php | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/lib/public/Authentication/TwoFactorAuth/TwoFactorProviderForUserEnabled.php b/lib/public/Authentication/TwoFactorAuth/TwoFactorProviderForUserEnabled.php new file mode 100644 index 00000000000..9172358cd16 --- /dev/null +++ b/lib/public/Authentication/TwoFactorAuth/TwoFactorProviderForUserEnabled.php @@ -0,0 +1,49 @@ +<?php + +declare(strict_types=1); + +/** + * SPDX-FileCopyrightText: 2021 Nextcloud GmbH and Nextcloud contributors + * SPDX-License-Identifier: AGPL-3.0-or-later + */ +namespace OCP\Authentication\TwoFactorAuth; + +use OCP\EventDispatcher\Event; +use OCP\IUser; + +/** + * @since 22.0.0 + * @deprecated 28.0.0 Use \OCP\Authentication\TwoFactorAuth\TwoFactorProviderChallengePassed instead + * @see \OCP\Authentication\TwoFactorAuth\TwoFactorProviderChallengePassed + */ +class TwoFactorProviderForUserEnabled extends Event { + /** @var IProvider */ + private $provider; + + /** @var IUser */ + private $user; + + /** + * @since 22.0.0 + */ + public function __construct(IUser $user, IProvider $provider) { + $this->user = $user; + $this->provider = $provider; + } + + /** + * @return IUser + * @since 22.0.0 + */ + public function getUser(): IUser { + return $this->user; + } + + /** + * @return IProvider + * @since 22.0.0 + */ + public function getProvider(): IProvider { + return $this->provider; + } +} |