We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent dafda82 commit 026c72cCopy full SHA for 026c72c
inertia/http.py
@@ -160,7 +160,7 @@ def build_first_load_context_and_template(self, data):
160
161
162
class InertiaResponse(BaseInertiaResponseMixin, HttpResponse):
163
- json_encoder = settings.INERTIA_JSON_ENCODER
+ json_encoder = None
164
165
def __init__(
166
self,
@@ -178,7 +178,10 @@ def __init__(
178
self.template_data = template_data or {}
179
_headers = headers or {}
180
181
- data = json_encode(self.page_data(), cls=self.json_encoder)
+ data = json_encode(
182
+ self.page_data(),
183
+ cls=self.json_encoder or settings.INERTIA_JSON_ENCODER,
184
+ )
185
186
if self.request.is_inertia():
187
_headers = {
0 commit comments