FengLiuFeseliud / pycqBot

go-cqhttp python 框架,可以用于快速塔建 bot
https://fengliufeseliud.github.io/pycqBot/
GNU Affero General Public License v3.0
129 stars 29 forks source link

为Request_Event增加了获取flag的函数以保证可以进行同意或者拒绝的操作 #28

Closed Seikaijyu closed 1 year ago

Seikaijyu commented 1 year ago

这个更改允许了同意或拒绝请求,实例如下

class myCqBot(cqBot):
    # 好友请求
    def request_friend(self, event: Request_Event):
        self.cqapi.set_friend_add_request(flag=event.get_flag(), approve=True)