Skip to content
This repository was archived by the owner on Jun 2, 2023. It is now read-only.

Commit 13300d9

Browse files
committed
test suggested changes
1 parent 4ef5aeb commit 13300d9

File tree

2 files changed

+13
-5
lines changed

2 files changed

+13
-5
lines changed

.golangci.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,9 @@ linters:
2727
- gochecknoinits
2828
- scopelint
2929
- dupl
30+
- typecheck
3031

3132
# golangci.com configuration
3233
# https://github.com/golangci/golangci/wiki/Configuration
3334
service:
34-
golangci-lint-version: 1.13.x # use fixed version to not introduce new linters unexpectedly
35+
golangci-lint-version: 1.15.x # use fixed version to not introduce new linters unexpectedly

internal/shared/logutil/log.go

+11-4
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
11
package logutil
22

3+
import "fmt"
4+
35
type Func func(format string, args ...interface{})
46

7+
8+
9+
510
type Log interface {
6-
Fatalf(format string, args ...interface{})
7-
Errorf(format string, args ...interface{})
8-
Warnf(format string, args ...interface{})
11+
Fatalf(format string, args ...interface{})
12+
Errorf(format string, args ...interface{})
13+
Warnf(format string, args ...interface{})
914
Infof(format string, args ...interface{})
1015
Debugf(key string, format string, args ...interface{})
1116

@@ -15,6 +20,7 @@ type Log interface {
1520

1621
type LogLevel int
1722

23+
// setup levellign
1824
const (
1925
// debug message, write to debug logs only by logutils.Debug
2026
LogLevelDebug LogLevel = 0
@@ -29,5 +35,6 @@ const (
2935

3036
// only not hidden from user errors: whole program failing, usually
3137
// error logging happens in 1-2 places: in the "main" function.
32-
LogLevelError LogLevel = 3
38+
LogLevelError LogLevel = 3
3339
)
40+

0 commit comments

Comments
 (0)