Skip to content

Commit

Permalink
fix: set JSONRenderer as the DEFAULT_RENDERER_CLASSES
Browse files Browse the repository at this point in the history
in production environments, it's not the best practice to have a browsable API and normally only a json should be returned.

Close #34
  • Loading branch information
CodeWithEmad committed Mar 11, 2024
1 parent f68719d commit c52eb18
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tutornotes/templates/notes/apps/settings/tutor.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,7 @@
},
}

{%- if ENABLE_HTTPS %}
REST_FRAMEWORK["DEFAULT_RENDERER_CLASSES"] = ("rest_framework.renderers.JSONRenderer",)
{%- endif %}
{{ patch("notes-settings") }}

0 comments on commit c52eb18

Please sign in to comment.