From 560caf837768a39d7e13f067f9221347ad348774 Mon Sep 17 00:00:00 2001 From: jmechnich Date: Sat, 1 Oct 2022 11:05:12 +0200 Subject: Fix PHP8 strtime warning if argument is null (addendum) --- classes/counters.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'classes/counters.php') diff --git a/classes/counters.php b/classes/counters.php index bc4d2d4a3..9699cb97c 100644 --- a/classes/counters.php +++ b/classes/counters.php @@ -193,7 +193,7 @@ class Counters { } // hide default un-updated timestamp i.e. 1970-01-01 (?) -fox - if ((int)date('Y') - (int)date('Y', strtotime($line['last_updated'])) > 2) + if ((int)date('Y') - (int)date('Y', strtotime($line['last_updated'] ?? '')) > 2) $last_updated = ''; $cv = [ -- cgit v1.2.3