Skip to content

Commit

Permalink
Removed adding index during handle duplicated key out of error message.
Browse files Browse the repository at this point in the history
  • Loading branch information
namsonx committed Jan 24, 2024
1 parent 296c948 commit 2c56238
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion JsonPreprocessor/CJsonPreprocessor.py
Original file line number Diff line number Diff line change
Expand Up @@ -723,7 +723,7 @@ def __loadNestedValue(initValue: str, sInputStr: str, bKey=False, key=''):
if CNameMangling.DUPLICATEDKEY_00.value in valueProcessed:
valueProcessed = valueProcessed.replace(CNameMangling.DUPLICATEDKEY_00.value, '')
elif CNameMangling.DUPLICATEDKEY_02.value in valueProcessed:
valueProcessed = valueProcessed.replace(CNameMangling.DUPLICATEDKEY_02.value, '')
valueProcessed = re.sub("(" + CNameMangling.DUPLICATEDKEY_02.value + "[0-9]*)", "", valueProcessed)
raise Exception(f"The variable '{valueProcessed}' is not available!")
if bKey and type(ldict['value']) in [list, dict]:
if CNameMangling.AVOIDDATATYPE.value in valueProcessed:
Expand Down

0 comments on commit 2c56238

Please sign in to comment.