some more tweaking to get CORS to work
This commit is contained in:
parent
94d1eabc79
commit
7edb65f426
|
@ -9,7 +9,7 @@ class AllowOriginMiddleware(object):
|
|||
def process_response(self, request, response):
|
||||
origin = request.META.get('HTTP_ORIGIN')
|
||||
if origin:
|
||||
response['Access-Control-Allow-Origin'] = origin
|
||||
response['Access-Control-Allow-Origin'] = '*'
|
||||
response['Access-Control-Allow-Methods'] = 'POST, GET, OPTIONS, DELETE, PUT'
|
||||
response['Access-Control-Allow-Headers'] = 'Content-Type, Accept'
|
||||
return response
|
||||
|
|
Loading…
Reference in New Issue
Block a user