You've already forked filebrowser
mirror of
https://github.com/filebrowser/filebrowser.git
synced 2025-11-26 14:25:26 +08:00
chore: fix golangci-lint errors
This commit is contained in:
@@ -1,15 +1,17 @@
|
||||
package bolt
|
||||
|
||||
import (
|
||||
"errors"
|
||||
|
||||
"github.com/asdine/storm/v3"
|
||||
|
||||
"github.com/filebrowser/filebrowser/v2/errors"
|
||||
fbErrors "github.com/filebrowser/filebrowser/v2/errors"
|
||||
)
|
||||
|
||||
func get(db *storm.DB, name string, to interface{}) error {
|
||||
err := db.Get("config", name, to)
|
||||
if err == storm.ErrNotFound {
|
||||
return errors.ErrNotExist
|
||||
if errors.Is(err, storm.ErrNotFound) {
|
||||
return fbErrors.ErrNotExist
|
||||
}
|
||||
|
||||
return err
|
||||
|
||||
Reference in New Issue
Block a user