mirror of
https://github.com/supermemoryai/supermemory.git
synced 2026-10-01 02:01:40 +00:00
Merge cfcee9621c into cfa6c7cb17
This commit is contained in:
commit
07d261d9a2
1 changed files with 10 additions and 4 deletions
|
|
@ -132,9 +132,12 @@ export async function validateApiKey(
|
|||
})
|
||||
return user
|
||||
} catch (error) {
|
||||
console.error("API key validation error:", error)
|
||||
const transient = transientAuthErrorFor(error)
|
||||
if (transient) throw transient
|
||||
if (transient) {
|
||||
console.error("Auth backend transient failure:", error)
|
||||
throw transient
|
||||
}
|
||||
console.debug("API key validation rejected:", error)
|
||||
return null
|
||||
}
|
||||
}
|
||||
|
|
@ -183,9 +186,12 @@ export async function validateOAuthToken(
|
|||
expiresAt: payload.exp,
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("OAuth token validation error:", error)
|
||||
const transient = transientAuthErrorFor(error)
|
||||
if (transient) throw transient
|
||||
if (transient) {
|
||||
console.error("Auth backend transient failure:", error)
|
||||
throw transient
|
||||
}
|
||||
console.debug("OAuth token validation rejected:", error)
|
||||
return null
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue