summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabien Potencier <fabien.potencier@gmail.com>2011-08-14 10:54:09 +0200
committerFabien Potencier <fabien.potencier@gmail.com>2011-08-14 10:54:09 +0200
commitd06bc2e2354a570a2754ef3186c7cde848f5677c (patch)
treedc808d567e4d0ebae2c4cec115771dfd61397d6c
parentfa4b69a12979d49baeb177c81da1c318de361df2 (diff)
parent8791cf2de673ca3b066c37cb9988cd9fe52d177f (diff)
downloadsymfony-security-d06bc2e2354a570a2754ef3186c7cde848f5677c.zip
symfony-security-d06bc2e2354a570a2754ef3186c7cde848f5677c.tar.gz
symfony-security-d06bc2e2354a570a2754ef3186c7cde848f5677c.tar.bz2
merged branch aboks/acl_voter (PR #1954)
Commits ------- 09c41d3 [Security] Fixed incorrect merge of two modifications (53f5c23c and 85199677) to AclVoter Discussion ---------- [Security] Fixed incorrect merge of two modifications to AclVoter It seems two modifications to `AclVoter` (53f5c23c and 85199677) have been merged incorrectly, leading to a method call on an object that is known to be `null` and a fatal error when running the tests
-rw-r--r--Acl/Voter/AclVoter.php11
1 files changed, 5 insertions, 6 deletions
diff --git a/Acl/Voter/AclVoter.php b/Acl/Voter/AclVoter.php
index 574b5c2..7dd80f1 100644
--- a/Acl/Voter/AclVoter.php
+++ b/Acl/Voter/AclVoter.php
@@ -82,14 +82,13 @@ class AclVoter implements VoterInterface
$this->logger->debug(sprintf('Object identity unavailable. Voting to %s', $this->allowIfObjectIdentityUnavailable? 'grant access' : 'abstain'));
}
- if (!$this->supportsClass($oid->getType())) {
- return self::ACCESS_ABSTAIN;
- }
-
- $sids = $this->securityIdentityRetrievalStrategy->getSecurityIdentities($token);
-
return $this->allowIfObjectIdentityUnavailable ? self::ACCESS_GRANTED : self::ACCESS_ABSTAIN;
}
+
+ if (!$this->supportsClass($oid->getType())) {
+ return self::ACCESS_ABSTAIN;
+ }
+
$sids = $this->securityIdentityRetrievalStrategy->getSecurityIdentities($token);
try {