@@ -40,9 +40,6 @@ func Trace(str ...interface{}) {
40
40
return
41
41
}
42
42
entry := NewLogEntry (TraceLevel , nil , msg )
43
- if Mask {
44
- entry = entry .Mask ()
45
- }
46
43
if OutFormat == JSONFormat {
47
44
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
48
45
} else {
@@ -59,9 +56,6 @@ func Debug(str ...interface{}) {
59
56
return
60
57
}
61
58
entry := NewLogEntry (DebugLevel , nil , fmt .Sprint (str ... ))
62
- if Mask {
63
- entry = entry .Mask ()
64
- }
65
59
if OutFormat == JSONFormat {
66
60
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
67
61
} else {
@@ -78,9 +72,6 @@ func Info(str ...interface{}) {
78
72
return
79
73
}
80
74
entry := NewLogEntry (InfoLevel , nil , fmt .Sprint (str ... ))
81
- if Mask {
82
- entry = entry .Mask ()
83
- }
84
75
if OutFormat == JSONFormat {
85
76
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
86
77
} else {
@@ -97,9 +88,6 @@ func Warn(str ...interface{}) {
97
88
return
98
89
}
99
90
entry := NewLogEntry (WarnLevel , nil , fmt .Sprint (str ... ))
100
- if Mask {
101
- entry = entry .Mask ()
102
- }
103
91
if OutFormat == JSONFormat {
104
92
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
105
93
} else {
@@ -116,9 +104,6 @@ func Error(str ...interface{}) {
116
104
return
117
105
}
118
106
entry := NewLogEntry (ErrorLevel , nil , fmt .Sprint (str ... ))
119
- if Mask {
120
- entry = entry .Mask ()
121
- }
122
107
if OutFormat == JSONFormat {
123
108
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
124
109
} else {
@@ -135,9 +120,6 @@ func Fatal(str ...interface{}) {
135
120
return
136
121
}
137
122
entry := NewLogEntry (FatalLevel , nil , fmt .Sprint (str ... ))
138
- if Mask {
139
- entry = entry .Mask ()
140
- }
141
123
if OutFormat == JSONFormat {
142
124
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
143
125
} else {
@@ -155,9 +137,6 @@ func Tracef(format string, args ...interface{}) {
155
137
return
156
138
}
157
139
entry := NewLogEntryf (TraceLevel , nil , format , args ... )
158
- if Mask {
159
- entry = entry .Mask ()
160
- }
161
140
if OutFormat == JSONFormat {
162
141
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
163
142
} else {
@@ -174,9 +153,6 @@ func Debugf(format string, args ...interface{}) {
174
153
return
175
154
}
176
155
entry := NewLogEntryf (DebugLevel , nil , format , args ... )
177
- if Mask {
178
- entry = entry .Mask ()
179
- }
180
156
if OutFormat == JSONFormat {
181
157
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
182
158
} else {
@@ -193,9 +169,6 @@ func Infof(format string, args ...interface{}) {
193
169
return
194
170
}
195
171
entry := NewLogEntryf (InfoLevel , nil , format , args ... )
196
- if Mask {
197
- entry = entry .Mask ()
198
- }
199
172
if OutFormat == JSONFormat {
200
173
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
201
174
} else {
@@ -212,9 +185,6 @@ func Warnf(format string, args ...interface{}) {
212
185
return
213
186
}
214
187
entry := NewLogEntryf (WarnLevel , nil , format , args ... )
215
- if Mask {
216
- entry = entry .Mask ()
217
- }
218
188
if OutFormat == JSONFormat {
219
189
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
220
190
} else {
@@ -231,9 +201,6 @@ func Errorf(format string, args ...interface{}) {
231
201
return
232
202
}
233
203
entry := NewLogEntryf (ErrorLevel , nil , format , args ... )
234
- if Mask {
235
- entry = entry .Mask ()
236
- }
237
204
if OutFormat == JSONFormat {
238
205
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
239
206
} else {
@@ -250,9 +217,6 @@ func Fatalf(format string, args ...interface{}) {
250
217
return
251
218
}
252
219
entry := NewLogEntryf (FatalLevel , nil , format , args ... )
253
- if Mask {
254
- entry = entry .Mask ()
255
- }
256
220
if OutFormat == JSONFormat {
257
221
_ , _ = GetWriter ().Write ([]byte (entry .JSONString () + "\n " ))
258
222
} else {
@@ -281,9 +245,6 @@ type LogEngineImpl struct {
281
245
282
246
func (engine * LogEngineImpl ) toString (lvl LogLevel , mask bool , str string ) (string , * LogEntry ) {
283
247
entry := NewLogEntry (lvl , engine .attributes , str )
284
- if mask {
285
- entry = entry .Mask ()
286
- }
287
248
if OutFormat == JSONFormat {
288
249
return entry .JSONString () + "\n " , entry
289
250
}
@@ -295,9 +256,6 @@ func (engine *LogEngineImpl) toString(lvl LogLevel, mask bool, str string) (stri
295
256
296
257
func (engine * LogEngineImpl ) toStringf (lvl LogLevel , mask bool , format string , args ... interface {}) (string , * LogEntry ) {
297
258
entry := NewLogEntryf (lvl , engine .attributes , format , args ... )
298
- if mask {
299
- entry = entry .Mask ()
300
- }
301
259
if OutFormat == JSONFormat {
302
260
return entry .JSONString () + "\n " , entry
303
261
}
0 commit comments