diff --git a/docs/ref/contrib/admin/actions.txt b/docs/ref/contrib/admin/actions.txt index 3b5de92d70..62f944d9b6 100644 --- a/docs/ref/contrib/admin/actions.txt +++ b/docs/ref/contrib/admin/actions.txt @@ -216,7 +216,7 @@ objects as JSON:: def export_as_json(modeladmin, request, queryset): response = HttpResponse(mimetype="text/javascript") - serialize.serialize(queryset, stream=response) + serializers.serialize("json", queryset, stream=response) return response Generally, something like the above isn't considered a great idea. Most of the