delete Twitter notice if it was posted from here

This commit is contained in:
Evan Prodromou
2010-09-05 01:17:56 -04:00
parent ba8a24073f
commit b059a19e0f
2 changed files with 42 additions and 0 deletions

View File

@@ -324,4 +324,20 @@ class TwitterOAuthClient extends OAuthClient
$status = json_decode($response);
return $status;
}
/**
* Calls Twitter's /statuses/destroy API method
*
* @param int $id ID of the status to destroy
*
* @return object destroyed
*/
function statusesDestroy($id)
{
$url = "http://api.twitter.com/1/statuses/destroy/$id.json";
$response = $this->oAuthPost($url);
$status = json_decode($response);
return $status;
}
}