mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-14 08:34:39 +00:00
Logs: add backward compatibility (#5522)
This commit is contained in:
parent
52d3e7c676
commit
f530e4fb4b
@ -102,7 +102,7 @@ if __name__ == '__main__':
|
||||
'timestamp': None,
|
||||
'parser': None,
|
||||
'facility': 1,
|
||||
'severity': 3,
|
||||
'severity': None,
|
||||
'process_name': '',
|
||||
'pid': None,
|
||||
'rnum': row_number
|
||||
@ -124,7 +124,7 @@ if __name__ == '__main__':
|
||||
record['parser'] = frmt.name
|
||||
else:
|
||||
record['line'] = rec['line']
|
||||
if len(severity) == 0 or record['severity'] in severity:
|
||||
if len(severity) == 0 or record['severity'] is None or record['severity'] in severity:
|
||||
result['total_rows'] += 1
|
||||
if (len(result['rows']) < limit or limit == 0) and result['total_rows'] >= offset:
|
||||
result['rows'].append(record)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user