@@ -39,27 +39,27 @@ |
||
39 | 39 | */ |
40 | 40 | interface IRegistry { |
41 | 41 | |
42 | - /** |
|
43 | - * Get a key-value map of providers and their enabled/disabled state for |
|
44 | - * the given user. |
|
45 | - * |
|
46 | - * @since 14.0.0 |
|
47 | - * @return string[] where the array key is the provider ID (string) and the |
|
48 | - * value is the enabled state (bool) |
|
49 | - */ |
|
50 | - public function getProviderStates(IUser $user): array; |
|
42 | + /** |
|
43 | + * Get a key-value map of providers and their enabled/disabled state for |
|
44 | + * the given user. |
|
45 | + * |
|
46 | + * @since 14.0.0 |
|
47 | + * @return string[] where the array key is the provider ID (string) and the |
|
48 | + * value is the enabled state (bool) |
|
49 | + */ |
|
50 | + public function getProviderStates(IUser $user): array; |
|
51 | 51 | |
52 | - /** |
|
53 | - * Enable the given 2FA provider for the given user |
|
54 | - * |
|
55 | - * @since 14.0.0 |
|
56 | - */ |
|
57 | - public function enableProviderFor(IProvider $provider, IUser $user); |
|
52 | + /** |
|
53 | + * Enable the given 2FA provider for the given user |
|
54 | + * |
|
55 | + * @since 14.0.0 |
|
56 | + */ |
|
57 | + public function enableProviderFor(IProvider $provider, IUser $user); |
|
58 | 58 | |
59 | - /** |
|
60 | - * Disable the given 2FA provider for the given user |
|
61 | - * |
|
62 | - * @since 14.0.0 |
|
63 | - */ |
|
64 | - public function disableProviderFor(IProvider $provider, IUser $user); |
|
59 | + /** |
|
60 | + * Disable the given 2FA provider for the given user |
|
61 | + * |
|
62 | + * @since 14.0.0 |
|
63 | + */ |
|
64 | + public function disableProviderFor(IProvider $provider, IUser $user); |
|
65 | 65 | } |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @copyright 2018 Christoph Wurst <[email protected]> |
@@ -31,38 +31,38 @@ |
||
31 | 31 | */ |
32 | 32 | class ProviderSet { |
33 | 33 | |
34 | - /** @var IProvider */ |
|
35 | - private $providers; |
|
34 | + /** @var IProvider */ |
|
35 | + private $providers; |
|
36 | 36 | |
37 | - /** @var bool */ |
|
38 | - private $providerMissing; |
|
37 | + /** @var bool */ |
|
38 | + private $providerMissing; |
|
39 | 39 | |
40 | - /** |
|
41 | - * @param array $providers |
|
42 | - * @param bool $providerMissing |
|
43 | - */ |
|
44 | - public function __construct(array $providers, bool $providerMissing) { |
|
45 | - $this->providers = $providers; |
|
46 | - $this->providerMissing = $providerMissing; |
|
47 | - } |
|
40 | + /** |
|
41 | + * @param array $providers |
|
42 | + * @param bool $providerMissing |
|
43 | + */ |
|
44 | + public function __construct(array $providers, bool $providerMissing) { |
|
45 | + $this->providers = $providers; |
|
46 | + $this->providerMissing = $providerMissing; |
|
47 | + } |
|
48 | 48 | |
49 | - /** |
|
50 | - * @param string $providerId |
|
51 | - * @return IProvider|null |
|
52 | - */ |
|
53 | - public function getProvider(string $providerId) { |
|
54 | - return $this->providers[$providerId] ?? null; |
|
55 | - } |
|
49 | + /** |
|
50 | + * @param string $providerId |
|
51 | + * @return IProvider|null |
|
52 | + */ |
|
53 | + public function getProvider(string $providerId) { |
|
54 | + return $this->providers[$providerId] ?? null; |
|
55 | + } |
|
56 | 56 | |
57 | - /** |
|
58 | - * @return IProvider[] |
|
59 | - */ |
|
60 | - public function getProviders(): array { |
|
61 | - return $this->providers; |
|
62 | - } |
|
57 | + /** |
|
58 | + * @return IProvider[] |
|
59 | + */ |
|
60 | + public function getProviders(): array { |
|
61 | + return $this->providers; |
|
62 | + } |
|
63 | 63 | |
64 | - public function isProviderMissing(): bool { |
|
65 | - return $this->providerMissing; |
|
66 | - } |
|
64 | + public function isProviderMissing(): bool { |
|
65 | + return $this->providerMissing; |
|
66 | + } |
|
67 | 67 | |
68 | 68 | } |