From 6c0e77891f30d3614d74f81165e624fec2becd9b Mon Sep 17 00:00:00 2001 From: Cayo Puigdefabregas Date: Thu, 28 Nov 2024 16:37:38 +0100 Subject: [PATCH] fix cors origin --- did/views.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/did/views.py b/did/views.py index 493925d..2c834ea 100644 --- a/did/views.py +++ b/did/views.py @@ -84,7 +84,9 @@ class PublicDeviceWebView(TemplateView): def get_json_response(self): device_data = self.get_result() # device_data = self.get_device_data() - return JsonResponse(device_data) + response = JsonResponse(device_data) + response["Access-Control-Allow-Origin"] = "*" + return response def get_result(self): components = []