Renamed function

This commit is contained in:
Michael 2019-12-21 18:24:43 +00:00
parent 26ac9a0063
commit 33cb241ed3

View file

@ -26,13 +26,7 @@ class SearchDirectory
return; return;
} }
self::discoverDirectory($search); $data = Cache::get('SearchDirectory:' . $search);
return;
}
private static function discoverDirectory($search)
{
$data = Cache::get('discoverDirectory' . $search);
if (!is_null($data)) { if (!is_null($data)) {
// Only search for the same item every 24 hours // Only search for the same item every 24 hours
if (time() < $data + (60 * 60 * 24)) { if (time() < $data + (60 * 60 * 24)) {
@ -86,6 +80,6 @@ class SearchDirectory
} }
} }
} }
Cache::set('discoverDirectory' . $search, time(), Cache::DAY); Cache::set('SearchDirectory:' . $search, time(), Cache::DAY);
} }
} }