0

好吧,这段代码有效,当一个人在 Telegram 上使用机器人并且他没有订阅我的频道时,它会告诉他在使用它之前加入,它工作正常,但它存在一些问题,例如有人加入了频道它会向他们提供相同的信息,直到他们离开频道并再次加入,然后才能与他们一起工作。我怎么解决这个问题 ??

        pp = []
        async for x in event.client.iter_participants("channel username"):
           pp.append(x.id)
        if (user.id) not in pp:
           return await xxx.edit(
               "U Must Subscribe This Channel To Use This Bot",
              buttons=[Button.url("JOIN CHANNEL", url="channel link")],
          )
4

0 回答 0