Commit 53b92a61 authored by Dries's avatar Dries
Browse files

- by default, keep the watchdog for one week rather then two weeks
  (http://drop.org/admin.php?op=watchdog is gets way to lengthy)
parent 312c625c
......@@ -24,7 +24,7 @@ function watchdog($id, $message) {
db_query("INSERT INTO watchdog (level, timestamp, user, message, location, hostname) VALUES ('". $watchdog[$id][0] ."', '". time() ."', '". check_input($user->id) ."', '". check_input($message) ."', '". check_input(getenv("REQUEST_URI")) ."', '". check_input(getenv("REMOTE_ADDR")) ."')");
}
function watchdog_clean($history = "604800") {
function watchdog_clean($history = 302400) {
$timestamp = time() - $history;
db_query("DELETE FROM watchdog WHERE timestamp < $timestamp");
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment