From: Nathan Yergler Date: Sun, 13 Nov 2011 20:07:09 +0000 (-0800) Subject: Issue 653: This time for sure! X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=d9ed3aeb402fc66de2a79d145b5a443c9e660c18;p=mediagoblin.git Issue 653: This time for sure! --- diff --git a/mediagoblin/middleware/csrf.py b/mediagoblin/middleware/csrf.py index d0601af8..8275c18e 100644 --- a/mediagoblin/middleware/csrf.py +++ b/mediagoblin/middleware/csrf.py @@ -98,7 +98,7 @@ class CsrfMiddleware(object): httponly=True) # update the Vary header - response.vary = (getattr(response, 'vary') or []) + ['Cookie'] + response.vary = (getattr(response, 'vary', None) or []) + ['Cookie'] def _make_token(self, request): """Generate a new token to use for CSRF protection."""