mirror of
https://github.com/kellyjonbrazil/jc.git
synced 2025-06-19 00:17:51 +02:00
simplify return condition formatting
This commit is contained in:
@ -65,6 +65,7 @@ def _process(proc_data):
|
|||||||
List of Dictionaries. Structured to conform to the schema.
|
List of Dictionaries. Structured to conform to the schema.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
# process the data here
|
||||||
# rebuild output for added semantic information
|
# rebuild output for added semantic information
|
||||||
# use helper functions in jc.utils for int, float, bool conversions and timestamps
|
# use helper functions in jc.utils for int, float, bool conversions and timestamps
|
||||||
|
|
||||||
@ -93,10 +94,9 @@ def parse(data, raw=False, quiet=False):
|
|||||||
if jc.utils.has_data(data):
|
if jc.utils.has_data(data):
|
||||||
|
|
||||||
for line in filter(None, data.splitlines()):
|
for line in filter(None, data.splitlines()):
|
||||||
# parse the content
|
#
|
||||||
|
# parse the content here
|
||||||
|
#
|
||||||
pass
|
pass
|
||||||
|
|
||||||
if raw:
|
return raw_output if raw else _process(raw_output)
|
||||||
return raw_output
|
|
||||||
else:
|
|
||||||
return _process(raw_output)
|
|
||||||
|
Reference in New Issue
Block a user