fix(ci): guard telegram native command auth typing

This commit is contained in:
Peter Steinberger 2026-03-28 04:54:09 +00:00
parent 090a767754
commit dc87ffa46d
2 changed files with 5 additions and 2 deletions

View File

@ -186,7 +186,10 @@ async function resolveTelegramCommandAuth(params: {
const chatId = msg.chat.id;
const isGroup = msg.chat.type === "group" || msg.chat.type === "supergroup";
const messageThreadId = (msg as { message_thread_id?: number }).message_thread_id;
const getChat: TelegramGetChat = bot.api.getChat.bind(bot.api);
const getChat =
typeof bot.api.getChat === "function"
? (bot.api.getChat.bind(bot.api) as TelegramGetChat)
: undefined;
const isForum = await resolveTelegramForumFlag({
chatId,
chatType: msg.chat.type,

View File

@ -132,7 +132,7 @@ describe("applyExclusiveSlotSelection", () => {
config,
selectedId,
...(selectedKind ? { selectedKind } : {}),
...(registry ? { registry } : {}),
...(registry ? { registry: { plugins: [...registry.plugins] } } : {}),
});
});