mirror of
https://github.com/docmost/docmost.git
synced 2026-08-25 00:52:13 +10:00
chore(integration): document cache purge intent
This commit is contained in:
@@ -105,7 +105,7 @@ export function useDisconnectIntegration() {
|
|||||||
queryKey: ["integration-connection", variables.integrationId],
|
queryKey: ["integration-connection", variables.integrationId],
|
||||||
});
|
});
|
||||||
qc.invalidateQueries({ queryKey: ["my-connections"] });
|
qc.invalidateQueries({ queryKey: ["my-connections"] });
|
||||||
// removeQueries, not invalidate: refetchOnMount false would revive stale entries
|
// removeQueries, not invalidate: refetchOnMount false leaves invalidated inactive queries unrefreshed
|
||||||
qc.removeQueries({ queryKey: ["unfurl"] });
|
qc.removeQueries({ queryKey: ["unfurl"] });
|
||||||
},
|
},
|
||||||
onError: (error) => {
|
onError: (error) => {
|
||||||
|
|||||||
@@ -123,6 +123,7 @@ export class UnfurlService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
|
// best-effort by design: never fail a disconnect on cache purge; the TTL is the backstop
|
||||||
this.logger.error(
|
this.logger.error(
|
||||||
`Failed to purge unfurl cache for user ${userId}: ${(err as Error).message}`,
|
`Failed to purge unfurl cache for user ${userId}: ${(err as Error).message}`,
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user