From: Zach Copley Date: Tue, 2 Nov 2010 23:13:20 +0000 (+0000) Subject: Output filename in log msg if one is supplied X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=764a297383ad8160b3e4d645d8953ef46a541b09;p=quix0rs-gnu-social.git Output filename in log msg if one is supplied --- diff --git a/lib/util.php b/lib/util.php index d50fa20814..47e52c9152 100644 --- a/lib/util.php +++ b/lib/util.php @@ -1499,6 +1499,7 @@ function common_request_id() function common_log($priority, $msg, $filename=null) { if(Event::handle('StartLog', array(&$priority, &$msg, &$filename))){ + $msg = (empty($filename)) ? $msg : basename($filename) . ' - ' . $msg; $msg = '[' . common_request_id() . '] ' . $msg; $logfile = common_config('site', 'logfile'); if ($logfile) {