]> git.wh0rd.org - tt-rss.git/blobdiff - public.php
pngcrush.sh
[tt-rss.git] / public.php
index 6ace943c411744af99d348a4e936673d80640f3a..7aebde78f378c7f1012cf122f2a727b878b9eb1f 100644 (file)
 
        $method = $_REQUEST["op"];
 
-       global $pluginhost;
-       $override = $pluginhost->lookup_handler("public", $method);
+       $override = PluginHost::getInstance()->lookup_handler("public", $method);
 
        if ($override) {
                $handler = $override;
        } else {
-               $handler = new Handler_Public( $_REQUEST);
+               $handler = new Handler_Public($_REQUEST);
        }
 
        if (implements_interface($handler, "IHandler") && $handler->before($method)) {
@@ -57,6 +56,5 @@
        }
 
        header("Content-Type: text/plain");
-       print json_encode(array("error" => array("code" => 7)));
-
+       print error_json(13);
 ?>