mirror of
https://github.com/WhatCD/Gazelle.git
synced 2025-01-18 12:11:36 +00:00
Empty commit
This commit is contained in:
parent
aaee6d4a4b
commit
8eaadadc2a
@ -7,11 +7,16 @@ class Permissions {
|
||||
* @param string $MinClass Return false if the user's class level is below this.
|
||||
*/
|
||||
public static function check_perms($PermissionName, $MinClass = 0) {
|
||||
|
||||
$OverrideClass = 1000;
|
||||
|
||||
$Override = G::$LoggedUser['EffectiveClass'] >= $OverrideClass;
|
||||
return (
|
||||
isset(G::$LoggedUser['Permissions'][$PermissionName])
|
||||
&& G::$LoggedUser['Permissions'][$PermissionName]
|
||||
&& (G::$LoggedUser['Class'] >= $MinClass
|
||||
|| G::$LoggedUser['EffectiveClass'] >= $MinClass)
|
||||
|| G::$LoggedUser['EffectiveClass'] >= $MinClass
|
||||
|| $Override)
|
||||
) ? true : false;
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
CHANGE LOG
|
||||
|
||||
2015-12-18 by newman
|
||||
Add override option in check_perms() for overriding $MinClass
|
||||
|
||||
2015-12-16 by lawnmower
|
||||
Fix adding donor points with decimals
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user