添加golangci-lint配置

This commit is contained in:
GoEdgeLab
2023-08-08 18:32:58 +08:00
parent 1f39947a89
commit f1fa608dcd
9 changed files with 84 additions and 9 deletions

View File

@@ -107,7 +107,7 @@ func MatchPath(action *actions.ActionObject, path string) bool {
// FindParentAction 查找父级Action
func FindParentAction(actionPtr actions.ActionWrapper) *ParentAction {
action, ok := actionPtr.(interface{
action, ok := actionPtr.(interface {
Parent() *ParentAction
})
if ok {
@@ -140,7 +140,7 @@ func findStack(err string) string {
filename = filename[strings.Index(filename, "src"):]
}
err += "\n\t\t" + string(filename) + ":" + fmt.Sprintf("%d", lineNo)
err += "\n\t\t" + filename + ":" + fmt.Sprintf("%d", lineNo)
break
}

View File

@@ -1,4 +1,4 @@
package recover
package recovers
import (
teaconst "github.com/TeaOSLab/EdgeAdmin/internal/const"

View File

@@ -1,6 +1,6 @@
// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
package recover
package recovers
import "github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils"

View File

@@ -1,4 +1,4 @@
package recover
package recovers
import "github.com/iwind/TeaGo"

View File

@@ -1,6 +1,6 @@
// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
package recover
package recovers
import (
"bytes"

View File

@@ -1,4 +1,4 @@
package recover
package recovers
import (
"encoding/json"

View File

@@ -1,4 +1,4 @@
package delete
package deletes
import ( "github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils"
"github.com/TeaOSLab/EdgeCommon/pkg/langs/codes"

View File

@@ -1,4 +1,4 @@
package delete
package deletes
import (
"github.com/TeaOSLab/EdgeAdmin/internal/configloaders"