X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Fapistatusnetversion.php;h=bbf891a899847d0bdbc8ba224deefaabea47ce4d;hb=0ab17f382b9993ada3d12d4cdace72cca53fb545;hp=2cd99edb7a83b9cdb91db91eed780b36623bea19;hpb=f746993c2bfb674d397cf095a2ab2ff7e757818b;p=quix0rs-gnu-social.git diff --git a/actions/apistatusnetversion.php b/actions/apistatusnetversion.php index 2cd99edb7a..bbf891a899 100644 --- a/actions/apistatusnetversion.php +++ b/actions/apistatusnetversion.php @@ -21,6 +21,7 @@ * * @category API * @package StatusNet + * @author Evan Prodromou * @author Zach Copley * @copyright 2009 StatusNet, Inc. * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 @@ -31,7 +32,7 @@ if (!defined('STATUSNET')) { exit(1); } -require_once INSTALLDIR . '/lib/api.php'; +require_once INSTALLDIR . '/lib/apiprivateauth.php'; /** * Returns a version number for this version of StatusNet, which @@ -41,12 +42,13 @@ require_once INSTALLDIR . '/lib/api.php'; * * @category API * @package StatusNet + * @author Evan Prodromou * @author Zach Copley * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 * @link http://status.net/ */ -class ApiStatusnetVersionAction extends TwitterApiAction +class ApiStatusnetVersionAction extends ApiPrivateAuthAction { /** * Take arguments for running @@ -77,19 +79,19 @@ class ApiStatusnetVersionAction extends TwitterApiAction switch ($this->format) { case 'xml': - $this->init_document('xml'); + $this->initDocument('xml'); $this->element('version', null, STATUSNET_VERSION); - $this->end_document('xml'); + $this->endDocument('xml'); break; case 'json': - $this->init_document('json'); + $this->initDocument('json'); print '"'.STATUSNET_VERSION.'"'; - $this->end_document('json'); + $this->endDocument('json'); break; default: $this->clientError( - _('API method not found!'), - 404, + _('API method not found!'), + 404, $this->format ); break;