Files
wehub-resource-sync 98e40dac97
CLI Smoke Test / smoke-test-linux (20) (push) Has been cancelled
CLI Smoke Test / smoke-test-linux (24) (push) Has been cancelled
CLI Smoke Test / smoke-test-windows (20) (push) Has been cancelled
CLI Smoke Test / smoke-test-windows (24) (push) Has been cancelled
Expo App TypeScript typecheck / typecheck (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:40:49 +08:00

15 lines
462 B
TypeScript

export class AbortedExeption extends Error {
constructor(message: string = "Operation aborted") {
super(message);
this.name = "AbortedExeption";
// This is needed to properly capture the stack trace in TypeScript
if (Error.captureStackTrace) {
Error.captureStackTrace(this, AbortedExeption);
}
}
static isAborted(error: unknown): boolean {
return error instanceof AbortedExeption;
}
}