From d373b7b452c6d64b47180940ed88c99c21bd9bc3 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Mon, 19 Dec 2022 21:36:50 +0300 Subject: * bring back cache-busting for feed icons based on timestamp * DiskCache: use singleton pattern to create less cache object instances * DiskCache: implement ETag --- classes/feeds.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'classes/feeds.php') diff --git a/classes/feeds.php b/classes/feeds.php index d34a23e4b..382d8dbf8 100755 --- a/classes/feeds.php +++ b/classes/feeds.php @@ -1163,7 +1163,7 @@ class Feeds extends Handler_Protected { } static function _get_icon_file(int $feed_id): string { - $favicon_cache = new DiskCache('feed-icons'); + $favicon_cache = DiskCache::instance('feed-icons'); return $favicon_cache->get_full_path((string)$feed_id); } @@ -1182,7 +1182,7 @@ class Feeds extends Handler_Protected { } static function _has_icon(int $feed_id): bool { - $favicon_cache = new DiskCache('feed-icons'); + $favicon_cache = DiskCache::instance('feed-icons'); return $favicon_cache->exists((string)$feed_id); } -- cgit v1.2.3-54-g00ecf