Ejemplo n.º 1
0
 /**
  * Checks if the given credentials correponds to a user that exists but
  * is not confirmed
  *
  * @param  array $credentials Array containing the credentials (email/username and password)
  *
  * @return  boolean Exists and is not confirmed?
  */
 public function existsButNotConfirmed($input)
 {
     $user = Confide::getUserByEmailOrUsername($input);
     if ($user) {
         return !$user->confirmed;
     }
 }
 /**
  * Checks if the given credentials correponds to a user that exists but
  * is not confirmed
  *
  * @param  array $credentials Array containing the credentials (email/username and password)
  *
  * @return  boolean Exists and is not confirmed?
  */
 public function existsButNotConfirmed($input)
 {
     $user = Confide::getUserByEmailOrUsername($input);
     if ($user) {
         $correctPassword = Hash::check(isset($input['password']) ? $input['password'] : false, $user->password);
         return !$user->confirmed && $correctPassword;
     }
 }
 /**
  * Find the user and check whether they are confirmed
  *
  * @param array $identity an array with identities to check (eg. ['username' => 'test'])
  * @return boolean
  */
 public function isConfirmed($identity)
 {
     $user = Confide::getUserByEmailOrUsername($identity);
     return $user && $user->confirmed;
 }