Commit 660ea7666b3922d7ce93eda074e170edcddb2832
Committed by
Christian Herdtweck
1 parent
8c9182a7
log_helper: remove constructor from JSON formatter
We only use it to initialize a field, but since it depends on an external module, it's better to avoid use it and prevent things from breaking if that changes.
Showing
1 changed file
with
1 additions
and
3 deletions
oletools/util/log_helper/_json_formatter.py
| ... | ... | @@ -6,9 +6,7 @@ class JsonFormatter(logging.Formatter): |
| 6 | 6 | """ |
| 7 | 7 | Format every message to be logged as a JSON object |
| 8 | 8 | """ |
| 9 | - def __init__(self, fmt=None, datefmt=None): | |
| 10 | - super(JsonFormatter, self).__init__(fmt, datefmt) | |
| 11 | - self._is_first_line = True | |
| 9 | + _is_first_line = True | |
| 12 | 10 | |
| 13 | 11 | def format(self, record): |
| 14 | 12 | """ | ... | ... |