- fixed problem with user_permission (reported by Kirstjan)
parent
171479fcfa
commit
282fbfd26a
|
@ -10,7 +10,7 @@ $watchdog = array("comment" => array("0", $submission_rate["comment"]),
|
|||
function watchdog($id, $message) {
|
||||
global $user, $watchdog, $watchdog_history;
|
||||
|
||||
if ($watchdog[$id][1] && !user_permission()) {
|
||||
if ($watchdog[$id][1] && !user_permission($user)) {
|
||||
if ($log = db_fetch_object(db_query("SELECT * FROM watchdog WHERE hostname = '". getenv("REMOTE_ADDR") ."' AND level = '". $watchdog[$id][0] ."'"))) {
|
||||
if (time() - $log->timestamp < $watchdog[$id][1]) {
|
||||
watchdog("warning", "'". getenv("REMOTE_ADDR") ."' exceeded '$id' submission rate");
|
||||
|
|
Loading…
Reference in New Issue