. * */ require_once('../lib/base.php'); use Symfony\Component\Routing\Exception\ResourceNotFoundException; use Symfony\Component\Routing\Exception\MethodNotAllowedException; try { OC::$server->getRouter()->match('/ocs'.OC_Request::getRawPathInfo()); } catch (ResourceNotFoundException $e) { OC_API::setContentType(); OC_OCS::notFound(); } catch (MethodNotAllowedException $e) { OC_API::setContentType(); OC_Response::setStatus(405); }