Piwik\Plugins\UsersManager\Model::getUserByTokenAuth PHP Method

getUserByTokenAuth() public method

public getUserByTokenAuth ( $tokenAuth )
    public function getUserByTokenAuth($tokenAuth)
    {
        $db = $this->getDb();
        return $db->fetchRow('SELECT * FROM ' . $this->table . ' WHERE token_auth = ?', $tokenAuth);
    }

Usage Example

Example #1
0
File: Auth.php Project: piwik/piwik
 private function authenticateWithToken($token)
 {
     $user = $this->userModel->getUserByTokenAuth($token);
     if (!empty($user['login'])) {
         return $this->authenticationSuccess($user);
     }
     return new AuthResult(AuthResult::FAILURE, null, $token);
 }
All Usage Examples Of Piwik\Plugins\UsersManager\Model::getUserByTokenAuth