Skip to content

Commit

Permalink
make sure we deal with arrays
Browse files Browse the repository at this point in the history
  • Loading branch information
m3nt0r committed Sep 22, 2010
1 parent 2b6dc4a commit b63696d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions controllers/components/acl_auth.php
Expand Up @@ -341,6 +341,9 @@ protected function _normalizePermissions($array, $targetArray = array()) {
if (is_numeric($action))
$action = $this->_Controller->action;

if (!is_array($requiredRoles))
$requiredRoles = array($requiredRoles);

// support inheritance
if (isset($targetArray["{$controller}/{$action}"])) {
$previousRoles = $targetArray["{$controller}/{$action}"];
Expand Down

0 comments on commit b63696d

Please sign in to comment.