diff options
author | Siebrand Mazeland <s.mazeland@xs4all.nl> | 2010-09-13 00:57:35 +0200 |
---|---|---|
committer | Siebrand Mazeland <s.mazeland@xs4all.nl> | 2010-09-13 21:10:55 +0200 |
commit | 39802077a861c2d4e15bae5f04c9f7dbf94151b8 (patch) | |
tree | 37ec392b728d05449b89b198c344dbdc55b9eeac /lib/apioauthstore.php | |
parent | 8c94ebf5375fe8ab9cb450525436396404d3fd33 (diff) |
* update/add translator documentation
* remove superfluous whitespace
Diffstat (limited to 'lib/apioauthstore.php')
-rw-r--r-- | lib/apioauthstore.php | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/lib/apioauthstore.php b/lib/apioauthstore.php index 1bb11cbca..84c4c78e5 100644 --- a/lib/apioauthstore.php +++ b/lib/apioauthstore.php @@ -23,7 +23,6 @@ require_once INSTALLDIR . '/lib/oauthstore.php'; class ApiStatusNetOAuthDataStore extends StatusNetOAuthDataStore { - function lookup_consumer($consumer_key) { $con = Consumer::staticGet('consumer_key', $consumer_key); @@ -39,7 +38,6 @@ class ApiStatusNetOAuthDataStore extends StatusNetOAuthDataStore function getAppByRequestToken($token_key) { // Look up the full req tokenx - $req_token = $this->lookup_token(null, 'request', $token_key); @@ -50,7 +48,6 @@ class ApiStatusNetOAuthDataStore extends StatusNetOAuthDataStore } // Look up the full Token - $token = new Token(); $token->tok = $req_token->key; $result = $token->find(true); @@ -150,7 +147,6 @@ class ApiStatusNetOAuthDataStore extends StatusNetOAuthDataStore } // Okay, good - return new OAuthToken($at->tok, $at->secret); } @@ -172,19 +168,18 @@ class ApiStatusNetOAuthDataStore extends StatusNetOAuthDataStore * * @return void */ - public function revoke_token($token_key, $type = 0) { $rt = new Token(); $rt->tok = $token_key; $rt->type = $type; $rt->state = 0; if (!$rt->find(true)) { - throw new Exception('Tried to revoke unknown token'); + // TRANS: Exception thrown when an attempt is made to revoke an unknown token. + throw new Exception(_('Tried to revoke unknown token')); } if (!$rt->delete()) { - throw new Exception('Failed to delete revoked token'); + // TRANS: Exception thrown when an attempt is made to remove a revoked token. + throw new Exception(_('Failed to delete revoked token')); } } - } - |