summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-05-08 19:01:45 +0000
committerBharat Mediratta <bharat@menalto.com>2009-05-08 19:01:45 +0000
commitbf3282cb3c4dfe1f4fae01e15515fa5a86d54bf2 (patch)
treef5e09e9a9f6fe090dc70fc7388af48cc86eede2a
parent764f88defb7afa2ec1cd1126fbeaa282a0b21d45 (diff)
Don't do ORM::factory() lookups on non-ints (thanks Romain LE DISEZ)
-rw-r--r--core/controllers/rest.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/controllers/rest.php b/core/controllers/rest.php
index b91bb0d0..c0451e7b 100644
--- a/core/controllers/rest.php
+++ b/core/controllers/rest.php
@@ -81,7 +81,7 @@ class REST_Controller extends Controller {
return $this->_index();
}
- $resource = ORM::factory($this->resource_type, $function);
+ $resource = ORM::factory($this->resource_type, (int)$function);
if (!$resource->loaded && $request_method != "post") {
return Kohana::show_404();
}