mirror of
https://github.com/pi-hole/web.git
synced 2024-12-06 19:36:21 +01:00
run date command right before log event
This commit is contained in:
+1
-1
@@ -4,9 +4,9 @@ $ERRORLOG = getenv('PHP_ERROR_LOG');
|
||||
if (empty($ERRORLOG)) {
|
||||
$ERRORLOG = '/var/log/lighttpd/error.log';
|
||||
}
|
||||
$date = exec("date +'%Y-%m-%d %H:%M:%S'");
|
||||
|
||||
function pi_log($message) {
|
||||
$date = exec("date +'%Y-%m-%d %H:%M:%S'");
|
||||
error_log($date . ': ' . $message . "\n", 3, $GLOBALS['ERRORLOG']);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user