Lines Matching refs:user
32 protected $user;
123 * Convenience method to get current user
129 if ($this->user === null) {
131 $this->user = $INPUT->server->str('REMOTE_USER');
134 if (!$this->user) {
135 throw new \RuntimeException('2fa user specifics used before user available');
137 return $this->user;
141 * Set the current user
143 * This is only needed when running 2fa actions for a non-logged-in user (e.g. during password reset)
145 public function setUser($user)
147 if ($this->user) {
148 throw new \RuntimeException('2fa user already set, cannot be changed');
150 $this->user = $user;
154 * Get or set the user opt-out state
156 * true: user opted out
157 * false: user did not opt out
189 $user = $this->getUser();
192 // initialize providers with user and ensure the ID is correct
198 $provider->init($user);
207 * Get all providers that have been already set up by the user
237 * Get the user's default provider if any
259 * Set the default provider for the user