mirror of
https://github.com/kellyjonbrazil/jc.git
synced 2025-07-13 01:20:24 +02:00
clean up raw/processed logic
This commit is contained in:
@ -136,10 +136,11 @@ def parse(data, raw=False, quiet=False):
|
||||
if jc.utils.has_data(data):
|
||||
has_data = True
|
||||
|
||||
# modified output with _ prefix for attributes
|
||||
raw_output = xmltodict.parse(data, attr_prefix='_')
|
||||
|
||||
if raw:
|
||||
if has_data:
|
||||
# modified output with _ prefix for attributes
|
||||
raw_output = xmltodict.parse(data, attr_prefix='_')
|
||||
|
||||
return raw_output
|
||||
else:
|
||||
return _process(data, has_data)
|
||||
|
||||
return _process(data, has_data)
|
||||
|
Reference in New Issue
Block a user