缓存测试成功

This commit is contained in:
hoteas
2021-05-28 23:48:33 +08:00
parent 1101937028
commit 339302956a
6 changed files with 40 additions and 35 deletions
+8 -5
View File
@@ -48,12 +48,15 @@ func (this *CacheRedis) reCon() bool {
return false
}
_, err = this.conn.Do("AUTH", this.Pwd)
if err != nil {
this.conn = nil
this.Error.SetError(err)
return false
if this.Pwd != "" {
_, err = this.conn.Do("AUTH", this.Pwd)
if err != nil {
this.conn = nil
this.Error.SetError(err)
return false
}
}
return true
}
func (this *CacheRedis) del(key string) {