Merge pull request #9196 from creative-commoners/pulls/3.7/pass-member-to-access

FIX Member argument is now passed to LeftAndMain::alternateAccessCheck()
This commit is contained in:
Garion Herman 2019-08-27 14:35:39 +12:00 committed by GitHub
commit 53f5c3d0e5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -194,8 +194,10 @@ class LeftAndMain extends Controller implements PermissionProvider {
// alternative extended checks // alternative extended checks
if ($this->hasMethod('alternateAccessCheck')) { if ($this->hasMethod('alternateAccessCheck')) {
$alternateAllowed = $this->alternateAccessCheck(); $alternateAllowed = $this->alternateAccessCheck($member);
if($alternateAllowed === FALSE) return false; if ($alternateAllowed === false) {
return false;
}
} }
// Check for "CMS admin" permission // Check for "CMS admin" permission