made the per-board mod functionality optional
This commit is contained in:
parent
e3cba2b450
commit
6f894ad4ee
@ -367,6 +367,9 @@
|
|||||||
// Permissions
|
// Permissions
|
||||||
// What level of administration you need to:
|
// What level of administration you need to:
|
||||||
|
|
||||||
|
// Don't worry about per-board moderators. Let all mods moderate any board.
|
||||||
|
$config['mod']['skip_per_board'] = true;
|
||||||
|
|
||||||
/* Post Controls */
|
/* Post Controls */
|
||||||
// View IP addresses
|
// View IP addresses
|
||||||
$config['mod']['show_ip'] = MOD;
|
$config['mod']['show_ip'] = MOD;
|
||||||
|
@ -15,6 +15,8 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
function hasPermission($action = null, $board = null, $_mod = null) {
|
function hasPermission($action = null, $board = null, $_mod = null) {
|
||||||
|
global $config;
|
||||||
|
|
||||||
if(isset($_mod))
|
if(isset($_mod))
|
||||||
$mod = &$_mod;
|
$mod = &$_mod;
|
||||||
else
|
else
|
||||||
@ -23,7 +25,7 @@
|
|||||||
if(isset($action) && $mod['type'] < $action)
|
if(isset($action) && $mod['type'] < $action)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if(isset($board) && !in_array($board, $mod['boards']))
|
if(isset($board) && !$config['mod']['skip_per_board'] && !in_array($board, $mod['boards']))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user