Merge pull request #1 from Charroja/deepsource-fix-643ae5b8

Omit redundant control flow
This commit is contained in:
Charroja
2021-05-01 22:38:00 +03:00
committed by GitHub
2 changed files with 3 additions and 4 deletions

View File

@@ -4,8 +4,9 @@ import (
"path/filepath"
"strings"
bolt "go.etcd.io/bbolt"
"server/log"
bolt "go.etcd.io/bbolt"
)
type TDB struct {
@@ -99,7 +100,6 @@ func (v *TDB) Set(xpath, name string, value []byte) {
log.TLogln("value:", value)
}
return
}
func (v *TDB) List(xpath string) []string {
@@ -173,5 +173,4 @@ func (v *TDB) Rem(xpath, name string) {
log.TLogln("Error rem sets", xpath+"/"+name, ", error:", err)
}
return
}

View File

@@ -211,5 +211,5 @@ func streamNoAuth(c *gin.Context) {
}
c.Header("WWW-Authenticate", "Basic realm=Authorization Required")
c.AbortWithStatus(http.StatusUnauthorized)
return
}