diff options
| author | Bharat Mediratta <bharat@menalto.com> | 2008-11-11 07:29:48 +0000 |
|---|---|---|
| committer | Bharat Mediratta <bharat@menalto.com> | 2008-11-11 07:29:48 +0000 |
| commit | 87f1115113f36b197003a45f32f295bb4cd19891 (patch) | |
| tree | 59859acf700871f1b20e2e1e04f53911b7573363 /core/config/routes.php | |
| parent | d35f337b7bc719ed0a4534ca835abbfa46d24a18 (diff) | |
Change REST API to use non-routable functions: _get(), _post(),
_put(), _delete().
This should make it more obvious that these are not your typical
routes, simplifies overall routing by removing a rule and removes the
possibility of accidentally leaking information if we route to one of
them by accident.
Diffstat (limited to 'core/config/routes.php')
| -rw-r--r-- | core/config/routes.php | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/core/config/routes.php b/core/config/routes.php index 9b958df1..24e2d73c 100644 --- a/core/config/routes.php +++ b/core/config/routes.php @@ -20,12 +20,10 @@ // REST configuration // Any resource requests (eg: album/1 or comment/3) get dispatched to the REST -// dispatcher. Any direct calls to REST methods are also forced into the dispatcher -// since the REST methods are internally expecting an ORM, not an id. +// dispatcher, and the abstract REST_Controller is not directly routable. $config['^rest'] = null; $config['^rest/.*'] = null; $config['^(\w+)/(\d+)$'] = '$1/dispatch/$2'; -$config['^(\w+)/(?:get|post|put|delete)/(\d+)$'] = '$1/dispatch/$2'; // For now our default page is the scaffolding. $config['_default'] = 'welcome'; |
