From c655388eaf7eb746c4c0269048b48218308a416a Mon Sep 17 00:00:00 2001 From: bbangert Date: Sun, 20 Aug 2006 23:45:25 +0000 Subject: Fix bug in is_xhr, should be HTTP_ header. --- paste/wsgiwrappers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'paste/wsgiwrappers.py') diff --git a/paste/wsgiwrappers.py b/paste/wsgiwrappers.py index 79cb8a6..b1ec7bd 100644 --- a/paste/wsgiwrappers.py +++ b/paste/wsgiwrappers.py @@ -60,7 +60,7 @@ class WSGIRequest(object): def is_xhr(self): """Returns a boolean if X-Requested-With is present and a XMLHttpRequest""" - return self.environ.get('X-Requested-With', '') == 'XMLHttpRequest' + return self.environ.get('HTTP_X-Requested-With', '') == 'XMLHttpRequest' is_xhr = property(is_xhr, doc=is_xhr.__doc__) def host(self): -- cgit v1.2.1