From 61c57be45a6dc47c498ac72339195855ceaea53c Mon Sep 17 00:00:00 2001 From: Keyrxng <106303466+Keyrxng@users.noreply.github.com> Date: Sun, 8 Sep 2024 15:35:59 +0100 Subject: [PATCH] chore: test --- src/bot/mtproto-api/workrooms.ts | 2 ++ src/handlers/callbacks-proxy.ts | 4 ---- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/bot/mtproto-api/workrooms.ts b/src/bot/mtproto-api/workrooms.ts index 343b226..94fac7e 100644 --- a/src/bot/mtproto-api/workrooms.ts +++ b/src/bot/mtproto-api/workrooms.ts @@ -19,6 +19,8 @@ export async function createChat(context: Context<"issues.labeled", SupportedEve }) ); + console.log("Chat created: ", chat); + // await context.adapters.supabase.chats.saveChat(chatId, payload.issue.title, payload.issue.node_id); return { status: 200, reason: "chat_created" }; diff --git a/src/handlers/callbacks-proxy.ts b/src/handlers/callbacks-proxy.ts index 9c8a37e..b589224 100644 --- a/src/handlers/callbacks-proxy.ts +++ b/src/handlers/callbacks-proxy.ts @@ -96,13 +96,10 @@ export function proxyWorkflowCallbacks(context: Context): ProxyCallbacks { return (async () => { try { await Promise.all(target[prop].map((callback) => handleCallback(callback, context))); - console.log("Finished workflow callback"); } catch (er) { context.logger.error(`Failed to handle event ${prop}`, { er }); await exit(1); } - - console.log("Exiting workflow callback"); await exit(0); })(); }, @@ -131,6 +128,5 @@ function handleCallback(callback: Function, context: Context) { * 1 - Failure */ async function exit(status: number = 0) { - console.log("Exiting with status: ", status); process.exit(status); } \ No newline at end of file