Example #1
0
 /**
  * @inheritdoc
  */
 public static function findIdentityByAccessToken($token, $type = null)
 {
     $oauthToken = OauthAccessTokens::findOne(['access_token' => $token]);
     if ($oauthToken) {
         return static::findOne(['id' => $oauthToken->user_id]);
     }
     //        throw new NotSupportedException('"findIdentityByAccessToken" is not implemented.');
 }
Example #2
0
File: User.php Project: hiqdev/hi3a
 /**
  * @inheritdoc
  */
 public static function findIdentityByAccessToken($access_token, $type = null)
 {
     $token = OauthAccessTokens::findOne(compact('access_token'));
     return static::findByUsername($token->user_id);
 }
Example #3
0
 public function findToken($access_token)
 {
     return OauthAccessTokens::findOne($access_token);
 }