X-Git-Url: https://git.wh0rd.org/?a=blobdiff_plain;f=public.php;h=8477f95fc8399f1f4959ed635b3c27e750b67e92;hb=2eee85448123824138ef3cc5ca56c9b20f016b79;hp=2cec82962b786a6f75b544d3b0da52520f9e5fcb;hpb=5f0a3741d0a549849b503eca7b6d7b87d9903069;p=tt-rss.git diff --git a/public.php b/public.php index 2cec8296..8477f95f 100644 --- a/public.php +++ b/public.php @@ -1,5 +1,6 @@ lookup_handler("public", $method); + + if ($override) { + $handler = $override; + } else { + $handler = new Handler_Public($link, $_REQUEST); + } - if ($handler) { - if ($handler->before()) { - if ($method && method_exists($handler, $method)) { - $handler->$method(); - } else if (method_exists($handler, 'index')) { - $handler->index(); - } - $handler->after(); - return; + if (implements_interface($handler, "IHandler") && $handler->before($method)) { + if ($method && method_exists($handler, $method)) { + $handler->$method(); + } else if (method_exists($handler, 'index')) { + $handler->index(); } + $handler->after(); + return; } header("Content-Type: text/plain");