fix unreachable code & missing stringer-generated code
This commit is contained in:
@@ -47,7 +47,7 @@ func (l Level) String() string {
|
||||
case Error:
|
||||
return "error"
|
||||
default:
|
||||
return fmt.Sprintf("%s", l)
|
||||
return fmt.Sprintf("%s", string(l))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -72,7 +72,7 @@ func (l *Logger) WithField(field string, val interface{}) *Logger {
|
||||
defer l.mtx.Unlock()
|
||||
|
||||
if _, ok := l.fields[field]; ok {
|
||||
fmt.Fprintf(os.Stderr, "%s caller overwrites field '%s'. Stack:\n%s\n", InternalErrorPrefix, string(debug.Stack()))
|
||||
fmt.Fprintf(os.Stderr, "%s caller overwrites field '%s'. Stack:\n%s\n", InternalErrorPrefix, field, string(debug.Stack()))
|
||||
}
|
||||
|
||||
child := &Logger{
|
||||
|
||||
Reference in New Issue
Block a user