Exemplo n.º 1
0
 /**
  * Checks if the user is logged in.
  *
  * @see PHPixie\Auth\Login\Provider::check_login()
  * @return bool If the user is logged in
  */
 public function check_login()
 {
     if (parent::check_login()) {
         return true;
     }
     $token = $this->pixie->cookie->get('login_token', null);
     if ($token === null) {
         return false;
     }
     return $this->login_token($token);
 }
Exemplo n.º 2
0
 /**
  * Checks if the user is logged in with facebook, if so
  * notifies the associated Service instance about it.
  * 
  * @return bool If the user is logged in
  */
 public function check_login()
 {
     if (parent::check_login()) {
         $this->access_token = $this->pixie->session->get($this->access_token_key);
         $this->token_expires = $this->pixie->session->get($this->token_expires_key);
         return true;
     }
     return false;
 }