From fd6e750e8065b7026a597f2adb044c0e78106954 Mon Sep 17 00:00:00 2001 From: Michael Date: Sun, 27 Sep 2020 08:11:43 +0000 Subject: [PATCH] Tags: Use the parameters for the cache key --- src/Model/Tag.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Model/Tag.php b/src/Model/Tag.php index 0d6c9cfb5..c4ff34c18 100644 --- a/src/Model/Tag.php +++ b/src/Model/Tag.php @@ -537,7 +537,7 @@ class Tag */ public static function getLocalTrendingHashtags(int $period, $limit = 10) { - $tags = DI::cache()->get('local_trending_tags'); + $tags = DI::cache()->get('local_trending_tags-' . $period . '-' . $limit); if (!empty($tags)) { return $tags; } else { @@ -563,7 +563,7 @@ class Tag if (DBA::isResult($tagsStmt)) { $tags = DBA::toArray($tagsStmt); - DI::cache()->set('local_trending_tags', $tags, Duration::HOUR); + DI::cache()->set('local_trending_tags-' . $period . '-' . $limit, $tags, Duration::HOUR); return $tags; }