* fixes a problem with security (/foo/bar and /foo///bar are not the same URL as far as security is concerned) * this can still be done in your web server configuration or by adding a core.request listener
@@ -106,7 +106,6 @@ class UrlMatcher implements UrlMatcherInterface
$url = substr($url, 0, $pos);
}
- // remove multiple /
- return preg_replace('#/+#', '/', $url);
+ return $url;
@@ -25,7 +25,6 @@ class UrlMatcherTest extends \PHPUnit_Framework_TestCase
$matcher = new UrlMatcherForTests($collection, array(), array());
$this->assertEquals('/foo', $matcher->normalizeUrl('/foo?foo=bar'), '->normalizeUrl() removes the query string');
- $this->assertEquals('/foo/bar', $matcher->normalizeUrl('/foo//bar'), '->normalizeUrl() removes duplicated /');
public function testMatch()