feat: enhance message sending with optional parse mode

This commit is contained in:
Kyle Fang
2025-07-24 20:24:35 +08:00
parent e9e1dc439f
commit a3be94f53e
2 changed files with 3 additions and 3 deletions

View File

@@ -1,2 +0,0 @@
pnpm 9.5.0
nodejs 20.5.1

View File

@@ -48,7 +48,9 @@ router.post("/t/:webhookId/raw", async (context) => {
return;
}
const result = await context.req.body.text();
await sendToChat(JSON.parse(chat), result);
await sendToChat(JSON.parse(chat), result, {
parseMode: context.req.url.searchParams.get('parseMode') as 'HTML' | undefined,
});
context.res.body = { ok: true };
});