summaryrefslogtreecommitdiffstats
path: root/Core
diff options
context:
space:
mode:
authorFabien Potencier <fabien.potencier@gmail.com>2011-12-07 20:44:38 +0100
committerFabien Potencier <fabien.potencier@gmail.com>2011-12-07 20:44:38 +0100
commitd2bdba5c73733dbc45153658584f16b57126090c (patch)
tree8bb0939f22b5b3af32567c1fa7db8185a94dff09 /Core
parent8432044d96c3c8b49149d027ee1e2eca900d8fc0 (diff)
downloadsymfony-security-d2bdba5c73733dbc45153658584f16b57126090c.zip
symfony-security-d2bdba5c73733dbc45153658584f16b57126090c.tar.gz
symfony-security-d2bdba5c73733dbc45153658584f16b57126090c.tar.bz2
[Security] fixed castv2.0.7
Diffstat (limited to 'Core')
-rw-r--r--Core/SecurityContext.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/Core/SecurityContext.php b/Core/SecurityContext.php
index 1065163..6d11850 100644
--- a/Core/SecurityContext.php
+++ b/Core/SecurityContext.php
@@ -63,7 +63,11 @@ class SecurityContext implements SecurityContextInterface
$this->token = $this->authenticationManager->authenticate($this->token);
}
- return $this->accessDecisionManager->decide($this->token, (array) $attributes, $object);
+ if (!is_array($attributes)) {
+ $attributes = array($attributes);
+ }
+
+ return $this->accessDecisionManager->decide($this->token, $attributes, $object);
}
/**