Skip to content

Commit

Permalink
Fix issue with missing base on redirect route.
Browse files Browse the repository at this point in the history
The request data wasn't set in Router when redirect routes are processed.
This caused the base to become missing. This causes issues with applications
running in a subdirectory.
  • Loading branch information
markstory committed Oct 22, 2011
1 parent 841e7aa commit 32b48ec
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion lib/Cake/Network/CakeRequest.php
Expand Up @@ -34,7 +34,11 @@ class CakeRequest implements ArrayAccess {
* *
* @var array * @var array
*/ */
public $params = array(); public $params = array(
'plugin' => null,
'controller' => null,
'action' => null,
);


/** /**
* Array of POST data. Will contain form data as well as uploaded files. * Array of POST data. Will contain form data as well as uploaded files.
Expand Down
2 changes: 1 addition & 1 deletion lib/Cake/Routing/Dispatcher.php
Expand Up @@ -75,8 +75,8 @@ public function dispatch(CakeRequest $request, CakeResponse $response, $addition
return; return;
} }


$request = $this->parseParams($request, $additionalParams);
Router::setRequestInfo($request); Router::setRequestInfo($request);
$request = $this->parseParams($request, $additionalParams);
$controller = $this->_getController($request, $response); $controller = $this->_getController($request, $response);


if (!($controller instanceof Controller)) { if (!($controller instanceof Controller)) {
Expand Down

0 comments on commit 32b48ec

Please sign in to comment.