🍱 fix lint :vomit:

This commit is contained in:
Max Lerebourg
2022-11-20 12:33:39 +01:00
parent 1dc50a8a8c
commit b37f866ca9
+4 -4
View File
@@ -173,10 +173,10 @@ func (bouncer *Bouncer) ServeHTTP(rw http.ResponseWriter, req *http.Request) {
// TODO This should be simplified // TODO This should be simplified
if bouncer.crowdsecMode != noneMode { if bouncer.crowdsecMode != noneMode {
isBanned, err := cache.GetDecision(remoteIP) isBanned, erro := cache.GetDecision(remoteIP)
if err != nil { if erro != nil {
logger.Debug(fmt.Sprintf("ServeHTTP:getDecision ip:%s %s", remoteIP, err.Error())) logger.Debug(fmt.Sprintf("ServeHTTP:getDecision ip:%s %s", remoteIP, erro.Error()))
if err.Error() == simpleredis.RedisUnreachable { if erro.Error() == simpleredis.RedisUnreachable {
rw.WriteHeader(http.StatusForbidden) rw.WriteHeader(http.StatusForbidden)
return return
} }