Commit 4e457abe authored by fred's avatar fred
Browse files

add json response to subscribe view

parent 04c365c3
......@@ -45,6 +45,8 @@ class SubscribeView(CreateView):
if not self.object.is_from_bot() and getattr(settings, 'NEWSLETTER_SEND_CONFIRMATION', True):
if self.request.headers.get('x-requested-with') == 'XMLHttpRequest':
return JsonResponse({'err': 0})
return resp
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment