mirror of
https://github.com/documenso/documenso.git
synced 2026-10-03 10:13:52 +10:00
Disable autocapture and person profiles for anonymous users, and redact signing tokens from captured URLs. Manually wire exception capture into the signing, editor and embed flows with recipient/envelope context for debugging recipient-reported issues. Track activation events (webhooks, api tokens, direct links, embed sessions) server-side with org attribution, and drop client events already tracked in-app.
15 lines
454 B
TypeScript
15 lines
454 B
TypeScript
/**
|
|
* Run a function without awaiting it or letting it affect the caller.
|
|
*
|
|
* Both synchronous throws and promise rejections are swallowed, making this
|
|
* safe to call from request handlers and loaders for side work such as
|
|
* analytics that must never block or fail the response.
|
|
*/
|
|
export const fireAndForget = (fn: () => unknown) => {
|
|
try {
|
|
void Promise.resolve(fn()).catch(() => null);
|
|
} catch {
|
|
// Swallow synchronous errors.
|
|
}
|
|
};
|