Beispiel #1
0
 /**
  * Auths the user by his/her id
  *
  * @param int $id
  */
 public function authUserById($id)
 {
     $user = Feusers::findFirstById($id);
     if ($user == false) {
         throw new Exception('The user does not exist');
     }
     $this->checkUserFlags($user);
     $this->session->set('auth', array('uid' => $user->id, 'username' => $user->name, 'profile' => $user->profile->name));
 }