]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge pull request #2718 from nslxndr/fix-log-endtime
authorSarah Hoffmann <lonvia@denofr.de>
Mon, 23 May 2022 14:25:41 +0000 (16:25 +0200)
committerGitHub <noreply@github.com>
Mon, 23 May 2022 14:25:41 +0000 (16:25 +0200)
Undefined offset in error log

lib-php/log.php

index b6d7a1a9fca482139d1573f41823ae918a9f632f..1d567733938d5afdbf783442c75ac9c5ccf5cf08 100644 (file)
@@ -78,7 +78,7 @@ function logEnd(&$oDB, $hLog, $iNumResults)
 
     if (CONST_Log_DB) {
         $aEndTime = explode('.', $fEndTime);
-        if (!$aEndTime[1]) {
+        if (!isset($aEndTime[1])) {
             $aEndTime[1] = '0';
         }
         $sEndTime = date('Y-m-d H:i:s', $aEndTime[0]).'.'.$aEndTime[1];