Procházet zdrojové kódy

Update SuggestionService

Daniel Supernault před 6 roky
rodič
revize
ef4a22949c
1 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. 2 2
      app/Services/SuggestionService.php

+ 2 - 2
app/Services/SuggestionService.php

@@ -34,9 +34,9 @@ class SuggestionService {
 		return self::del($val);
 	}
 
-	public static function warmCache()
+	public static function warmCache($force = false)
 	{
-		if(Redis::zcount(self::CACHE_KEY, '-inf', '+inf') == 0) {
+		if(Redis::zcount(self::CACHE_KEY, '-inf', '+inf') == 0 || $force == true) {
 			$ids = Profile::whereNull('domain')
 				->whereIsSuggestable(true)
 				->whereIsPrivate(false)