mirror of
https://github.com/supermemoryai/supermemory.git
synced 2026-10-21 05:18:00 +00:00
fix(web): preserve plugin revoke error cause
This commit is contained in:
parent
8ad25d05a4
commit
bad873c566
1 changed files with 2 additions and 1 deletions
|
|
@ -2836,7 +2836,8 @@ export function IntegrationsView({
|
|||
const handleRevokePluginKey = async (keyId: string) => {
|
||||
try {
|
||||
const result = await authClient.apiKey.delete({ keyId })
|
||||
if (result.error) throw new Error(result.error.message)
|
||||
if (result.error)
|
||||
throw new Error(result.error.message, { cause: result.error })
|
||||
const refreshed = await refetchKeys()
|
||||
if (refreshed.error) throw refreshed.error
|
||||
toast.success("Plugin disconnected")
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue