Skip to content

armgit / zulip

Public Imported from GitHub
0

Zulip server and web application. Open-source team chat that helps teams stay productive and focused.

registration: Instruct browser to not cache page.

Aman Agrawalcfe74415d6b2
diff --git a/zerver/views/registration.py b/zerver/views/registration.py
index 614ec4f1009..3623f8790fe 100644
--- a/zerver/views/registration.py
+++ b/zerver/views/registration.py
@@ -22,6 +22,7 @@ from django.urls import reverse
from django.utils.translation import get_language, gettext_lazy
from django.utils.translation import gettext as _
from django.utils.translation import override as override_language
+from django.views.decorators.cache import never_cache
from django_auth_ldap.backend import LDAPBackend, _LDAPUser
from pydantic import Json, NonNegativeInt, StringConstraints
@@ -264,6 +265,7 @@ def accounts_register(*args: Any, **kwargs: Any) -> HttpResponse:
return registration_helper(*args, **kwargs)
+@never_cache
@require_post
def import_realm_from_slack(*args: Any, **kwargs: Any) -> HttpResponse:
return registration_helper(*args, **kwargs)