You are here

function SimpleOAuthDataStore::lookup_consumer in OAuth 1.0 6

Overrides OAuthDataStore::lookup_consumer

File

./OAuth.php, line 675

Class

SimpleOAuthDataStore

Code

function lookup_consumer($consumer_key) {

  /*{{{*/
  $rv = dba_fetch("consumer_{$consumer_key}", $this->dbh);
  if ($rv === FALSE) {
    return NULL;
  }
  $obj = unserialize($rv);
  if (!$obj instanceof OAuthConsumer) {
    return NULL;
  }
  return $obj;
}