]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/apiaccountratelimitstatus.php
Merge branch 'openid-plugin' into 'nightly'
[quix0rs-gnu-social.git] / actions / apiaccountratelimitstatus.php
index 8d7f89eadccd4168c3fec52dd004a835b0a78a9e..592cf908fcf49d71dcfe896411361862b8180fe8 100644 (file)
  * @link      http://status.net/
  */
 
-if (!defined('STATUSNET')) {
-    exit(1);
-}
-
-require_once INSTALLDIR . '/lib/apibareauth.php';
+if (!defined('GNUSOCIAL')) { exit(1); }
 
 /**
  * We don't have a rate limit, but some clients check this method.
@@ -60,17 +56,17 @@ class ApiAccountRateLimitStatusAction extends ApiBareAuthAction
      *
      * @return void
      */
-    function handle($args)
+    protected function handle()
     {
-        parent::handle($args);
+        parent::handle();
 
         if (!in_array($this->format, array('xml', 'json'))) {
             $this->clientError(
+                // TRANS: Client error displayed when coming across a non-supported API method.
                 _('API method not found.'),
                 404,
                 $this->format
             );
-            return;
         }
 
         $reset   = new DateTime();