You are here

function MockOAuthDataStore::lookup_token in OAuth 1.0 6

Overrides OAuthDataStore::lookup_token

File

./OAuth_TestServer.php, line 72

Class

MockOAuthDataStore
A mock store for testing

Code

function lookup_token($consumer, $token_type, $token) {

  /*{{{*/
  $token_attrib = $token_type . "_token";
  if ($consumer->key == $this->consumer->key && $token == $this->{$token_attrib}->key) {
    return $this->{$token_attrib};
  }
  return NULL;
}