phantasmobile/app/item/utils.py
2023-07-24 19:08:30 +01:00

8 lines
194 B
Python

import json
from django.http import Http404, HttpResponse
def render_to_json(response):
content = json.dumps(response)
return HttpResponse(content, 'application/json; charset=utf-8')