revive: make type exportable and remove unnecessary log word
See, ``` log/gokit_adapter.go:9:26: unexported-return: exported func NewToolkitAdapter returns unexported type *log.logAdapter, which can be annoying to use (revive) func NewToolkitAdapter() *logAdapter { ^ ``` Signed-off-by: Mario Trangoni <mjtrangoni@gmail.com>
This commit is contained in:
parent
9e3c585a28
commit
df4f6b206b
|
@ -6,13 +6,13 @@ import (
|
|||
|
||||
// Returns an adapter implementing the go-kit/kit/log.Logger interface on our
|
||||
// logrus logger
|
||||
func NewToolkitAdapter() *logAdapter {
|
||||
return &logAdapter{}
|
||||
func NewToolkitAdapter() *Adapter {
|
||||
return &Adapter{}
|
||||
}
|
||||
|
||||
type logAdapter struct{}
|
||||
type Adapter struct{}
|
||||
|
||||
func (*logAdapter) Log(keyvals ...interface{}) error {
|
||||
func (*Adapter) Log(keyvals ...interface{}) error {
|
||||
var lvl level.Value
|
||||
var msg string
|
||||
for i := 0; i < len(keyvals); i += 2 {
|
||||
|
|
Loading…
Reference in New Issue