Ejemplo n.º 1
0
 /**
  * Create User
  * 
  * @param  Socialite $socialite
  * 
  * @return User      $user
  */
 public static function createUserFromOAuth($socialite)
 {
     $temp_pass = CustomLibrary::generateTempPass($socialite->token);
     $user = new self();
     $user->name = $socialite->getName();
     $user->email = $socialite->getEmail();
     $user->password = bcrypt($temp_pass);
     $user->save();
     // $this->emailTemporaryPassword($temp_pass);
     return $user;
 }