Permalink
Browse files

Controller: Fixing HTTP-method-specific bugs.

  • Loading branch information...
1 parent 702943a commit 75f620095725af5aae465945be1c6c055160fb8e @TomFrost committed Jan 4, 2012
Showing with 5 additions and 5 deletions.
  1. +5 −5 controller/Router.php
View
@@ -415,7 +415,7 @@ public function catchAll($defaults, $overrides=array(), $argOrder=null,
*/
public function delete($path, $defaults=null, $overrides=null,
$restrictions=null, $argOrder=null, $argsAsArray=false) {
- return request($path, $defaults, $overrides, $restrictions,
+ return $this->request($path, $defaults, $overrides, $restrictions,
$argOrder, $argsAsArray, 'DELETE');
}
@@ -449,7 +449,7 @@ public function delete($path, $defaults=null, $overrides=null,
*/
public function get($path, $defaults=null, $overrides=null,
$restrictions=null, $argOrder=null, $argsAsArray=false) {
- return request($path, $defaults, $overrides, $restrictions,
+ return $this->request($path, $defaults, $overrides, $restrictions,
$argOrder, $argsAsArray, 'GET');
}
@@ -562,7 +562,7 @@ protected function passRequest($controller, $function, $args=null,
*/
public function post($path, $defaults=null, $overrides=null,
$restrictions=null, $argOrder=null, $argsAsArray=false) {
- return request($path, $defaults, $overrides, $restrictions,
+ return $this->request($path, $defaults, $overrides, $restrictions,
$argOrder, $argsAsArray, 'POST');
}
@@ -653,7 +653,7 @@ protected function processPath($path, $restrictions=null, &$args=null) {
$path = str_replace('(', '(?:', $path, $openParens);
$path = str_replace(')', ')?', $path, $closeParens);
if ($openParens !== $closeParens) {
- throw new RouterSyntaxException(
+ throw new RouteSyntaxException(
"Unequal number of closing and opening parentheses in '" .
$path . "'.");
}
@@ -714,7 +714,7 @@ protected function processPath($path, $restrictions=null, &$args=null) {
*/
public function put($path, $defaults=null, $overrides=null,
$restrictions=null, $argOrder=null, $argsAsArray=false) {
- return request($path, $defaults, $overrides, $restrictions,
+ return $this->request($path, $defaults, $overrides, $restrictions,
$argOrder, $argsAsArray, 'PUT');
}

0 comments on commit 75f6200

Please sign in to comment.