Browse Source

Pass correct argument name to HttpResponse

Fixes compatibility with django 1.8.
pull/1/head
Hidden Z 9 years ago
parent
commit
8905486e3e
  1. 2
      pyi2phosts/api/views.py

2
pyi2phosts/api/views.py

@ -13,4 +13,4 @@ def all(request): @@ -13,4 +13,4 @@ def all(request):
for host in queryset:
# pass last_seen to json in unixtime
json_dict[get_b32(host.b64hash)] = host.last_seen.strftime("%s")
return HttpResponse(json.dumps(json_dict), mimetype="application/json")
return HttpResponse(json.dumps(json_dict), content_type="application/json")

Loading…
Cancel
Save