mirror of
https://github.com/Mrs4s/go-cqhttp.git
synced 2025-05-04 19:17:37 +08:00
fix: set_group_ban limit error (#1846)
* fix: set_group_ban limit error
This commit is contained in:
parent
a8bed3fc03
commit
2483eb09c4
@ -1166,7 +1166,7 @@ func (bot *CQBot) CQSetGroupBan(groupID, userID int64, duration uint32) global.M
|
||||
if m := g.FindMember(userID); m != nil {
|
||||
err := m.Mute(duration)
|
||||
if err != nil {
|
||||
if duration > 2592000 {
|
||||
if duration >= 2592000 {
|
||||
return Failed(100, "DURATION_IS_NOT_IN_RANGE", "非法的禁言时长")
|
||||
}
|
||||
return Failed(100, "NOT_MANAGEABLE", "机器人权限不足")
|
||||
|
Loading…
x
Reference in New Issue
Block a user