mirror of
https://github.com/supabase/supabase.git
synced 2026-10-10 11:55:05 +03:00
fix apple jwt expiry check
This commit is contained in:
1 parent
ed1fdb203d
commit
75ee97eb7d
1 file changed
+1
-1
@@ -614,7 +614,7 @@ const EXTERNAL_PROVIDER_APPLE = {
|
||||
try {
|
||||
const parts = value.split('.').map((value) => parseBase64URL(value))
|
||||
const body = JSON.parse(parts[1])
|
||||
return Date.now() < body.exp - 7 * 24 * 60 * 60 * 1000
|
||||
return Date.now() < body.exp * 1000 - 7 * 24 * 60 * 60 * 1000
|
||||
} catch (e: any) {
|
||||
console.log(e)
|
||||
return false
|
||||
|
||||
Reference in new issue
Block a user