Django 1.7 compatibility

fixes #77

Replaced `django.http.HttpResponse` with `django.http.JsonResponse` with fallback for Django < 1.7.