Skip to content

Commit 34ec3fe

Browse files
Merge branch '2.3' into 2.5
* 2.3: [TwigBridge] fix form requirement [CssSelector] added the license of the Python library we ported to PHP [SecurityBundle] avoid unneeded work Conflicts: src/Symfony/Bridge/Twig/composer.json
2 parents ff7533a + 69657e9 commit 34ec3fe

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

DependencyInjection/SecurityExtension.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -599,17 +599,17 @@ private function createExpression($container, $expression)
599599

600600
private function createRequestMatcher($container, $path = null, $host = null, $methods = array(), $ip = null, array $attributes = array())
601601
{
602+
if ($methods) {
603+
$methods = array_map('strtoupper', (array) $methods);
604+
}
605+
602606
$serialized = serialize(array($path, $host, $methods, $ip, $attributes));
603607
$id = 'security.request_matcher.'.md5($serialized).sha1($serialized);
604608

605609
if (isset($this->requestMatchers[$id])) {
606610
return $this->requestMatchers[$id];
607611
}
608612

609-
if ($methods) {
610-
$methods = array_map('strtoupper', (array) $methods);
611-
}
612-
613613
// only add arguments that are necessary
614614
$arguments = array($path, $host, $methods, $ip, $attributes);
615615
while (count($arguments) > 0 && !end($arguments)) {

0 commit comments

Comments
 (0)