style: format unhandled rejection handler

This commit is contained in:
Peter Steinberger
2026-01-28 00:36:54 +00:00
parent 7eb57b691c
commit afd57c7e23

View File

@@ -14,11 +14,7 @@ const FATAL_ERROR_CODES = new Set([
"ERR_WORKER_INITIALIZATION_FAILED",
]);
const CONFIG_ERROR_CODES = new Set([
"INVALID_CONFIG",
"MISSING_API_KEY",
"MISSING_CREDENTIALS",
]);
const CONFIG_ERROR_CODES = new Set(["INVALID_CONFIG", "MISSING_API_KEY", "MISSING_CREDENTIALS"]);
// Network error codes that indicate transient failures (shouldn't crash the gateway)
const TRANSIENT_NETWORK_CODES = new Set([
@@ -145,10 +141,7 @@ export function installUnhandledRejectionHandler(): void {
}
if (isConfigError(reason)) {
console.error(
"[moltbot] CONFIGURATION ERROR - requires fix:",
formatUncaughtError(reason),
);
console.error("[moltbot] CONFIGURATION ERROR - requires fix:", formatUncaughtError(reason));
process.exit(1);
return;
}