Skip to content

Commit 1317e11

Browse files
committed
fix(response): revert #6
1 parent 8c602be commit 1317e11

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

response.go

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ package control
33
import (
44
"errors"
55
"strconv"
6-
7-
sql "github.com/FloatTech/sqlite"
86
)
97

108
// InitResponse ...
@@ -52,7 +50,6 @@ func (manager *Manager[CTX]) CanResponse(gid int64) bool {
5250
if ok {
5351
return ext != "-"
5452
}
55-
5653
var rsp ResponseGroup
5754
manager.RLock()
5855
err := manager.D.Find("__resp", &rsp, "where gid = 0") // all status
@@ -66,7 +63,7 @@ func (manager *Manager[CTX]) CanResponse(gid int64) bool {
6663
manager.RLock()
6764
err = manager.D.Find("__resp", &rsp, "where gid = "+strconv.FormatInt(gid, 10))
6865
manager.RUnlock()
69-
if err != nil && !errors.Is(err, sql.ErrNullResult) {
66+
if err != nil {
7067
manager.Lock()
7168
respCache[gid] = "-"
7269
manager.Unlock()

0 commit comments

Comments
 (0)