💩👌 make lint happy

This commit is contained in:
源文雨 2022-09-09 09:54:33 +08:00
parent 6f1ec04ac8
commit fafe24f1e4
3 changed files with 3 additions and 2 deletions

View File

@ -1,3 +1,4 @@
// Package main ZeroBot-Plugin main file
package main
import (

View File

@ -65,7 +65,7 @@ func init() {
msg = strings.ReplaceAll(msg, "\r", "")
msg = strings.ReplaceAll(msg, "\t", "")
msg = strings.ReplaceAll(msg, ";", "")
if db.isInAntiList(uid, gid, msg) {
if db.isInAntiList(gid, msg) {
if err := ctx.State["manager"].(*ctrl.Control[*zero.Ctx]).Manager.DoBlock(uid); err == nil {
t := time.Now().Unix()
cache.Set(uid, struct{}{})

View File

@ -50,7 +50,7 @@ func newantidb(path string) (*antidb, error) {
return db, nil
}
func (db *antidb) isInAntiList(uid, gid int64, msg string) bool {
func (db *antidb) isInAntiList(gid int64, msg string) bool {
grp := strconv.FormatInt(gid, 36)
db.RLock()
defer db.RUnlock()