mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-31 09:06:17 +00:00
Minor refactor of variable names.
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@8215 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
8971aad8bf
commit
f79a68b2a6
1 changed files with 4 additions and 4 deletions
|
@ -263,8 +263,8 @@ class AuthComponent extends Object {
|
||||||
*/
|
*/
|
||||||
function startup(&$controller) {
|
function startup(&$controller) {
|
||||||
$methods = array_flip($controller->methods);
|
$methods = array_flip($controller->methods);
|
||||||
$controllerAction = strtolower($controller->params['action']);
|
$action = strtolower($controller->params['action']);
|
||||||
$lowerAllowedActions = array_map('strtolower', $this->allowedActions);
|
$allowedActions = array_map('strtolower', $this->allowedActions);
|
||||||
|
|
||||||
$isErrorOrTests = (
|
$isErrorOrTests = (
|
||||||
strtolower($controller->name) == 'cakeerror' ||
|
strtolower($controller->name) == 'cakeerror' ||
|
||||||
|
@ -276,7 +276,7 @@ class AuthComponent extends Object {
|
||||||
|
|
||||||
$isMissingAction = (
|
$isMissingAction = (
|
||||||
$controller->scaffold === false &&
|
$controller->scaffold === false &&
|
||||||
!isset($methods[$controllerAction])
|
!isset($methods[$action])
|
||||||
);
|
);
|
||||||
|
|
||||||
if ($isMissingAction) {
|
if ($isMissingAction) {
|
||||||
|
@ -298,7 +298,7 @@ class AuthComponent extends Object {
|
||||||
|
|
||||||
$isAllowed = (
|
$isAllowed = (
|
||||||
$this->allowedActions == array('*') ||
|
$this->allowedActions == array('*') ||
|
||||||
in_array($controllerAction, $lowerAllowedActions)
|
in_array($action, $allowedActions)
|
||||||
);
|
);
|
||||||
|
|
||||||
if ($loginAction != $url && $isAllowed) {
|
if ($loginAction != $url && $isAllowed) {
|
||||||
|
|
Loading…
Add table
Reference in a new issue