diff --git a/apps/server/src/run-worker.ts b/apps/server/src/run-worker.ts index 326e9517..0bc2c7da 100644 --- a/apps/server/src/run-worker.ts +++ b/apps/server/src/run-worker.ts @@ -4,9 +4,7 @@ import "./sentry"; import * as Sentry from "@sentry/node"; import { runWorker } from "./worker/client"; -if (typeof require !== "undefined" && require.main === module) { - runWorker().catch((e) => { - Sentry.captureException(e); - console.error("Worker crashed", e); - }); -} +runWorker().catch((e) => { + Sentry.captureException(e); + console.error("Worker crashed", e); +});