Update HashtagService, reduce cached_count cache ttl

pull/4776/head
Daniel Supernault 2023-11-16 02:53:22 -07:00
rodzic 4aca04729b
commit 15f29f7d79
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 23740873EE6F76A1
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -29,7 +29,7 @@ class HashtagService
public static function count($id)
{
return Cache::remember('services:hashtag:public-count:by_id:' . $id, 3600, function() use($id) {
return Cache::remember('services:hashtag:total-count:by_id:' . $id, 300, function() use($id) {
$tag = Hashtag::find($id);
return $tag ? $tag->cached_count ?? 0 : 0;
});