You are here

public static function DrupalOAuthConsumer::deleteConsumer in OAuth 1.0 6.3

Same name and namespace in other branches
  1. 7.4 includes/DrupalOAuthConsumer.inc \DrupalOAuthConsumer::deleteConsumer()
  2. 7.3 includes/DrupalOAuthConsumer.inc \DrupalOAuthConsumer::deleteConsumer()

Deletes the consumer with the id from the database.

Parameters

string $csid: The consumer id.

Return value

void

1 call to DrupalOAuthConsumer::deleteConsumer()
DrupalOAuthConsumer::delete in includes/DrupalOAuthConsumer.inc
Deletes the consumer from the database

File

includes/DrupalOAuthConsumer.inc, line 121

Class

DrupalOAuthConsumer

Code

public static function deleteConsumer($csid) {

  //TODO: Add compatibility layer?
  db_query("DELETE c, pc, t, pt FROM {oauth_common_consumer} c\n      LEFT JOIN {oauth_common_provider_consumer} pc ON pc.csid = c.csid\n      LEFT JOIN {oauth_common_token} t ON t.csid = c.csid\n      LEFT JOIN {oauth_common_provider_token} pt ON pt.tid = t.tid\n      WHERE c.csid = %d", array(
    ':csid' => $csid,
  ));
}