Skip to content

Commit aa46d21

Browse files
committed
Remove json decoding
1 parent 0ed725a commit aa46d21

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

app/sdc/utils.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import copy
22

3-
import json
43
from urllib.parse import quote
54

65
from fhirpathpy.models import models
@@ -118,11 +117,10 @@ def parameter_to_env(resource):
118117
_name_key, value_key = param.keys()
119118
param_value = param[value_key]
120119
try:
121-
param_value = json.loads(param_value)
122120
polimorphic_key = first(param_value.keys())
123121
if polimorphic_key:
124122
env[param["name"]] = param_value[polimorphic_key]
125-
except (json.JSONDecodeError, AttributeError):
123+
except AttributeError:
126124
env[param["name"]] = param_value
127125
# Mapping parameters to fhir resource names
128126
questionnaire = env.get("questionnaire")

0 commit comments

Comments
 (0)