Permalink
Browse files

[HttpFoundation] fixed ApacheRequest

Pathinfo was incorrect when using mod_rewrite.
Added better test coverage.
  • Loading branch information...
1 parent fd777ab commit ecf9b6d4f3a1d08f959c637b0b72629a6c64d7f0 @kriswallsmith kriswallsmith committed Dec 21, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 ApacheRequest.php
View
@@ -46,6 +46,6 @@ protected function prepareBaseUrl()
*/
protected function preparePathInfo()
{
- return $this->server->get('PATH_INFO');
+ return $this->server->get('PATH_INFO') ?: substr($this->prepareRequestUri(), strlen($this->prepareBaseUrl())) ?: '/';
}
}

0 comments on commit ecf9b6d

Please sign in to comment.