From 59e6d0de03af1ac8c0f1537cd0b015ab9229bd4c Mon Sep 17 00:00:00 2001 From: Pas <74743263+Pasithea0@users.noreply.github.com> Date: Thu, 17 Apr 2025 15:19:50 -0600 Subject: [PATCH] use thirty min time for region --- src/utils/detectRegion.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/utils/detectRegion.tsx b/src/utils/detectRegion.tsx index 6e9c16c2..4b77dbf7 100644 --- a/src/utils/detectRegion.tsx +++ b/src/utils/detectRegion.tsx @@ -15,7 +15,8 @@ interface RegionStore { setRegion: (region: Region) => void; } -const TEN_DAYS_MS = 10 * 24 * 60 * 60 * 1000; +// const TEN_DAYS_MS = 10 * 24 * 60 * 60 * 1000; +const THIRTY_MINUTES_MS = 30 * 60 * 1000; export const useRegionStore = create()( persist( @@ -50,7 +51,7 @@ export async function detectRegion(): Promise { if ( store.region && store.lastChecked && - Date.now() - store.lastChecked < TEN_DAYS_MS + Date.now() - store.lastChecked < THIRTY_MINUTES_MS ) { return store.region; }