FeedbackBot.py 文件源码

python
阅读 19 收藏 0 点赞 0 评论 0

项目:TelegramBots 作者: d-qoi 项目源码 文件源码
def forwardToAll(bot, list_of_chats, from_chat_id, message_id):
    logger.debug("List of chats to forward a message to: %s" % list_of_chats)

    if not list_of_chats: #If there are no chats to foward to.
        return

    for chat in list_of_chats:
        try:
            bot.forward_message(chat_id=chat,
                                from_chat_id=from_chat_id,
                                message_id=message_id)
        except TelegramError as te:
            logger.debug("Unable to send message to %s from %s. May want to remove it, or resolve the thread." %(chat, from_chat_id))
            logger.debug("Error from forward to all: %s" % te)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号