mirror of
https://github.com/rico-vz/HeimerdingerLoL.git
synced 2025-12-06 10:10:48 +01:00
feat(cache): update cache expiration times
- Update the cache expiration time for 'championsListAllCache' and 'championsRolesCache' to 8 hours.
- Update the cache expiration time for 'championShowCache{slug}' to 3 days.
- Update the cache expiration time for 'championSplashColorCache{slug}' to 6 months.
- Update the cache expiration time for 'championSkinShowCache{slug}' to 48 hours.
- Update the cache expiration time for 'championSkinSplashColorCache{slug}' to 120 hours.
This commit is contained in:
@@ -56,14 +56,14 @@ class ChampionSkinController extends Controller
|
||||
{
|
||||
$skin = Cache::remember(
|
||||
'championSkinShowCache' . $championSkin->slug,
|
||||
60 * 60 * 8,
|
||||
static fn () => $championSkin->load('champion', 'chromas')
|
||||
60 * 60 * 48,
|
||||
static fn() => $championSkin->load('champion', 'chromas')
|
||||
);
|
||||
|
||||
$splashColor = Cache::remember(
|
||||
'championSkinSplashColorCache' . $championSkin->slug,
|
||||
60 * 60 * 24,
|
||||
static fn () => getAverageColorFromImageUrl($championSkin->getSkinImageAttribute())
|
||||
60 * 60 * 120,
|
||||
static fn() => getAverageColorFromImageUrl($championSkin->getSkinImageAttribute())
|
||||
);
|
||||
|
||||
$skin->splash_color = $splashColor;
|
||||
|
||||
Reference in New Issue
Block a user