From ac9dbd4b83852d137d35cb87911ebd6b21c494db Mon Sep 17 00:00:00 2001 From: Bart Visscher Date: Wed, 25 Jul 2012 17:45:29 +0200 Subject: [PATCH] Add functions for the common HTTP methods --- lib/route.php | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/lib/route.php b/lib/route.php index 4344c977113..0d3339add6c 100644 --- a/lib/route.php +++ b/lib/route.php @@ -19,6 +19,21 @@ class OC_Route extends Route { return $this; } + public function get() { + $this->method('get'); + return $this; + } + + public function put() { + $this->method('put'); + return $this; + } + + public function delete() { + $this->method('delete'); + return $this; + } + public function defaults($defaults) { $action = $this->getDefault('action'); $this->setDefaults($defaults);