diff options
author | Gabriel Hurley <gabriel@strikeawe.com> | 2012-08-09 19:00:49 -0700 |
---|---|---|
committer | Gabriel Hurley <gabriel@strikeawe.com> | 2012-08-09 19:02:03 -0700 |
commit | c96677576a21c8dc89b327c92c86d7964f12fe4a (patch) | |
tree | 623a8eac5493b755e7d75fc7276a4ef49d2b8979 /horizon/exceptions.py | |
parent | 87ef0db150d241ea98d3b582c55139a253bb6152 (diff) | |
download | horizon-c96677576a21c8dc89b327c92c86d7964f12fe4a.tar.gz |
Don't call a method that doesn't exist for unauth'd requests.
Fixes a broken method call in a previously untested code path.
Change-Id: I72343ba51f9871b4e85641d773b574fb218fb158
Diffstat (limited to 'horizon/exceptions.py')
-rw-r--r-- | horizon/exceptions.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/horizon/exceptions.py b/horizon/exceptions.py index f31455bb2..18303e9f9 100644 --- a/horizon/exceptions.py +++ b/horizon/exceptions.py @@ -23,6 +23,7 @@ import os import sys from django.conf import settings +from django.contrib.auth import logout from django.http import HttpRequest from django.utils import termcolors from django.utils.translation import ugettext as _ @@ -260,7 +261,7 @@ def handle(request, message=None, redirect=None, ignore=False, if issubclass(exc_type, UNAUTHORIZED): if ignore: return NotAuthorized - request.user_logout() + logout(request) if not force_silence and not handled: log_method(error_color("Unauthorized: %s" % exc_value)) if not handled: |