Merge pull request #11 from U188/patch-4

添加绑定指令
This commit is contained in:
764763903a 2021-09-08 00:10:21 +08:00 committed by GitHub
commit aaa3f149ac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -489,6 +489,20 @@ var codeSignals = []CodeSignal{
return nil
},
},
{
Command: []string{"绑定"},
Handle: func(sender *Sender) interface{} {
qq := Int(sender.Contents[0])
if len(sender.Contents) > 1 {
sender.Contents = sender.Contents[1:]
sender.handleJdCookies(func(ck *JdCookie) {
ck.Update(QQ, qq)
sender.Reply(fmt.Sprintf("已设置账号%s的QQ为%v。", ck.Nickname, ck.QQ))
})
}
return nil
},
},
{
Command: []string{"cmd", "command", "命令"},
Admin: true,