]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/OStatus/lib/salmonaction.php
Merge branch 'profile' into 'nightly'
[quix0rs-gnu-social.git] / plugins / OStatus / lib / salmonaction.php
index 13f49f4effa6fcfa4cacba5e7c1d58ba299e681a..4d2144c30056aa7a6512d5626c80e9683acc2f1b 100644 (file)
@@ -31,6 +31,8 @@ class SalmonAction extends Action
     protected $oprofile = null; // Ostatus_profile of the actor
     protected $actor    = null; // Profile object of the actor
 
+    var $format   = 'text'; // error messages will be printed in plaintext
+
     var $xml      = null;
     var $activity = null;
     var $target   = null;
@@ -43,7 +45,7 @@ class SalmonAction extends Action
 
         if (!isset($_SERVER['CONTENT_TYPE'])) {
             // TRANS: Client error. Do not translate "Content-type"
-            $this->clientError(_m('Salmon requires a Content-type header.'));
+            throw new ClientException(_m('Salmon requires a Content-type header.'));
         }
         $envxml = null;
         switch ($_SERVER['CONTENT_TYPE']) {