]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - actions/apiaccountupdateprofile.php
Merge branch 'testing' of git@gitorious.org:statusnet/mainline into testing
[quix0rs-gnu-social.git] / actions / apiaccountupdateprofile.php
index 8af0fb8660112b0fb53aa8429afe0e72ed88d23d..fd4384a25c465093f042cdeee6c4650ede04b245 100644 (file)
@@ -92,6 +92,15 @@ class ApiAccountUpdateProfileAction extends ApiAuthAction
             return;
         }
 
+        if (!in_array($this->format, array('xml', 'json'))) {
+            $this->clientError(
+                _('API method not found.'),
+                404,
+                $this->format
+            );
+            return;
+        }
+
         if (empty($this->user)) {
             $this->clientError(_('No such user.'), 404, $this->format);
             return;
@@ -135,7 +144,7 @@ class ApiAccountUpdateProfileAction extends ApiAuthAction
 
         if (!$result) {
             common_log_db_error($profile, 'UPDATE', __FILE__);
-            $this->serverError(_('Couldn\'t save profile.'));
+            $this->serverError(_('Could not save profile.'));
             return;
         }