From ab0d0c48068f5bb2388cdf6809393eb45462f70d Mon Sep 17 00:00:00 2001
From: Alice Heaton <aliceh@aptivate.org>
Date: Mon, 13 Jul 2015 10:17:31 +0100
Subject: [PATCH] Escaping single quotes in json embed tag is actually
 un-necessary (and breaks the data) since the single quotes are replaced with
 html entities.

---
 django/website/hid/templatetags/json_data.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/django/website/hid/templatetags/json_data.py b/django/website/hid/templatetags/json_data.py
index 80553c75..6b40f0fe 100644
--- a/django/website/hid/templatetags/json_data.py
+++ b/django/website/hid/templatetags/json_data.py
@@ -9,4 +9,4 @@ def json_data(value):
     """ Django custom template tag used to embed arbitrary
         values as json within html5 data- attributes.
     """
-    return json.dumps(value).replace("'", "\\'")
+    return json.dumps(value)
-- 
GitLab