mirror of
https://github.com/kellyjonbrazil/jc.git
synced 2025-07-13 01:20:24 +02:00
use None instead of --
This commit is contained in:
@ -35,14 +35,14 @@ def parse(data):
|
||||
for entry in cleandata:
|
||||
output_line = {}
|
||||
|
||||
# normalize data by inserting -- for missing data
|
||||
# normalize data by inserting Null for missing data
|
||||
temp_line = entry.split(maxsplit=len(headers) - 1)
|
||||
|
||||
for spec in header_spec:
|
||||
if spec[1] == 'COMMAND' or spec[1] == 'NAME':
|
||||
continue
|
||||
if entry[spec[2] - 1] == ' ':
|
||||
temp_line.insert(spec[0], '--')
|
||||
temp_line.insert(spec[0], None)
|
||||
|
||||
name = ' '.join(temp_line[9:])
|
||||
fixed_line = temp_line[0:9]
|
||||
|
Reference in New Issue
Block a user