diff --git a/edivorce/apps/core/templatetags/input_field.py b/edivorce/apps/core/templatetags/input_field.py index ffe4da3c..1fd6ecbc 100644 --- a/edivorce/apps/core/templatetags/input_field.py +++ b/edivorce/apps/core/templatetags/input_field.py @@ -54,10 +54,15 @@ def check_list(source, value): """ Check if given value is in the given source """ - return value in json.loads(source) + try: + return value in json.loads(source) + except: + return False @register.assignment_tag def multiple_values_to_list(source): - json_list = json.loads(source) - return json_list + try: + return json.loads(source) + except: + return []