Permalink
Browse files

load assertions from service manager

  • Loading branch information...
1 parent 36db670 commit e750d264e76872bd439890946ce9c410ac6f02db @bjyoungblood committed Sep 17, 2012
Showing with 4 additions and 0 deletions.
  1. +4 −0 src/BjyAuthorize/Service/Authorize.php
@@ -218,6 +218,10 @@ protected function loadRule(array $rule, $type)
throw new \InvalidArgumentException('Invalid rule definition: ' . print_r($rule, true));
}
+ if (is_string($assertion)) {
+ $assertion = $this->sl->get($assertion);
+ }
+
if ($type === static::TYPE_ALLOW) {
$this->acl->allow($roles, $resources, $privileges, $assertion);
} else {

0 comments on commit e750d26

Please sign in to comment.