From ab06eeff674ce7b59609957619eadf5a0e22fff7 Mon Sep 17 00:00:00 2001 From: PCoder Date: Wed, 27 Dec 2017 09:04:58 +0100 Subject: [PATCH] Add cache_control to SSHKEyCreateView and SettingsView post methods --- hosting/views.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosting/views.py b/hosting/views.py index 76be4a67..0b258536 100644 --- a/hosting/views.py +++ b/hosting/views.py @@ -547,6 +547,7 @@ class SSHKeyCreateView(LoginRequiredMixin, FormView): def get(self, request, *args, **kwargs): return render(request, self.template_name) + @cache_control(no_cache=True, must_revalidate=True, no_store=True) def post(self, request, *args, **kwargs): form = self.get_form() required = 'add_ssh' in self.request.POST @@ -596,6 +597,7 @@ class SettingsView(LoginRequiredMixin, FormView): def get(self, request, *args, **kwargs): return render(request, self.template_name) + @cache_control(no_cache=True, must_revalidate=True, no_store=True) def post(self, request, *args, **kwargs): form = self.get_form() if form.is_valid():