Only render comments in debug

This commit is contained in:
Jake Howard 2022-09-02 17:20:03 +01:00
parent 7fff13f0ab
commit 8691d11a15
Signed by: jake
GPG Key ID: 57AFB45680EDD477
2 changed files with 6 additions and 4 deletions

View File

@ -1,5 +1,7 @@
<div class="container">
<section class="container">
<div id="commento"></div>
</div>
</section>
<script async defer src="https://commento.theorangeone.net/js/commento.js"></script>
{% if not DEBUG %}
<script async defer src="https://commento.theorangeone.net/js/commento.js"></script>
{% endif %}

View File

@ -3,4 +3,4 @@ from django.http.request import HttpRequest
def global_vars(request: HttpRequest) -> dict:
return {"SEO_INDEX": settings.SEO_INDEX}
return {"SEO_INDEX": settings.SEO_INDEX, "DEBUG": settings.DEBUG}