style(telegram): format bot.ts
This commit is contained in:
@@ -966,7 +966,8 @@ export function createTelegramBot(opts: TelegramBotOptions) {
|
||||
msg.chat.type === "group" || msg.chat.type === "supergroup";
|
||||
const messageThreadId = (msg as { message_thread_id?: number })
|
||||
.message_thread_id;
|
||||
const isForum = (msg.chat as { is_forum?: boolean }).is_forum === true;
|
||||
const isForum =
|
||||
(msg.chat as { is_forum?: boolean }).is_forum === true;
|
||||
const storeAllowFrom = await readTelegramAllowFromStore().catch(
|
||||
() => [],
|
||||
);
|
||||
@@ -982,7 +983,8 @@ export function createTelegramBot(opts: TelegramBotOptions) {
|
||||
...(groupAllowOverride ?? groupAllowFrom ?? []),
|
||||
...storeAllowFrom,
|
||||
]);
|
||||
const hasGroupAllowOverride = typeof groupAllowOverride !== "undefined";
|
||||
const hasGroupAllowOverride =
|
||||
typeof groupAllowOverride !== "undefined";
|
||||
|
||||
if (isGroup && groupConfig?.enabled === false) {
|
||||
await bot.api.sendMessage(chatId, "This group is disabled.");
|
||||
|
||||
Reference in New Issue
Block a user