diff options
| author | Jannis Leidel | 2012-08-27 03:40:28 -0700 |
|---|---|---|
| committer | Jannis Leidel | 2012-08-27 03:40:28 -0700 |
| commit | a492b1746d4a8e58a24b8b5c179dc8147ab57c9c (patch) | |
| tree | 4a31eae94828d7ca00b030e8c606330d86ed025c | |
| parent | 83ca90650be659adac89010211497771bc0b7425 (diff) | |
| parent | 4d0b77e446c62e40387228aea39056424232b827 (diff) | |
| download | django-debug-toolbar-a492b1746d4a8e58a24b8b5c179dc8147ab57c9c.tar.bz2 | |
Merge pull request #314 from rickeyvisinski-kanban/ignorexmlhttprequest
prevent debug toolbar from inserting itself into a partial template
| -rw-r--r-- | debug_toolbar/middleware.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/debug_toolbar/middleware.py b/debug_toolbar/middleware.py index 6e86223..1979e1d 100644 --- a/debug_toolbar/middleware.py +++ b/debug_toolbar/middleware.py @@ -116,7 +116,7 @@ class DebugToolbarMiddleware(object): __traceback_hide__ = True ident = thread.get_ident() toolbar = self.__class__.debug_toolbars.get(ident) - if not toolbar: + if not toolbar or request.is_ajax(): return response if isinstance(response, HttpResponseRedirect): if not toolbar.config['INTERCEPT_REDIRECTS']: |
