small bug

This commit is contained in:
Michael Save 2012-02-18 01:14:13 +11:00
parent 25cdd35663
commit a4fe0d9d47

View File

@ -406,7 +406,7 @@
function hasPermission($action = null, $board = null, $_mod = null) { function hasPermission($action = null, $board = null, $_mod = null) {
global $config; global $config;
if(isset($_mod)) if(isset($_mod))
$mod = &$_mod; $mod = &$_mod;
else else
@ -415,10 +415,13 @@
if(isset($action) && $mod['type'] < $action) if(isset($action) && $mod['type'] < $action)
return false; return false;
if(!isset($board)) if(!isset($board) || $config['mod']['skip_per_board'])
return true; return true;
if(!$config['mod']['skip_per_board'] && !in_array('*', $mod['boards']) && !in_array($board, $mod['boards'])) if(!isest($mod['boards']))
return false;
if(!in_array('*', $mod['boards']) && !in_array($board, $mod['boards']))
return false; return false;
return true; return true;