From ada57d4384073d4b9893e769f622a93d52b8b0da Mon Sep 17 00:00:00 2001 From: Sarjuuk Date: Mon, 4 Sep 2017 16:45:57 +0200 Subject: [PATCH] Misc/Versions * AOWOW_REVISION is no longer expected to be numeric this allows for user-defined versions (e.g.4.1c) when changes within css/js files need to be forced into the web browser or existing cache files need to be invalidated --- pages/genericPage.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/genericPage.class.php b/pages/genericPage.class.php index a004430e..623df6a9 100644 --- a/pages/genericPage.class.php +++ b/pages/genericPage.class.php @@ -864,7 +864,7 @@ class GenericPage $type = $cache['isString']; $data = $cache['data']; - if ($cache['timestamp'] + CFG_CACHE_DECAY <= time() || $cache['revision'] < AOWOW_REVISION) + if ($cache['timestamp'] + CFG_CACHE_DECAY <= time() || $cache['revision'] != AOWOW_REVISION) $cache = null; else $this->cacheLoaded = [CACHE_MODE_MEMCACHED, $cache['timestamp']]; @@ -887,7 +887,7 @@ class GenericPage list($time, $rev, $type) = explode(' ', $cache[0]); - if ($time + CFG_CACHE_DECAY <= time() || $rev < AOWOW_REVISION) + if ($time + CFG_CACHE_DECAY <= time() || $rev != AOWOW_REVISION) $cache = null; else {