diff options
| author | Rob Hudson | 2008-09-07 10:56:54 -0700 |
|---|---|---|
| committer | Rob Hudson | 2008-09-07 10:56:54 -0700 |
| commit | 6a1e15b3c9f5658a26b77121af126a84258f8b0d (patch) | |
| tree | 5bea374e05acfcffc21e7a856d3cbd03ec838a87 /debug_toolbar/toolbar | |
| parent | 608d7fbddc708e840458a2ca956f8f7991406eff (diff) | |
| download | django-debug-toolbar-6a1e15b3c9f5658a26b77121af126a84258f8b0d.tar.bz2 | |
updating to pass around the request object
Diffstat (limited to 'debug_toolbar/toolbar')
| -rw-r--r-- | debug_toolbar/toolbar/loader.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/debug_toolbar/toolbar/loader.py b/debug_toolbar/toolbar/loader.py index f4cc068..5e0a9e4 100644 --- a/debug_toolbar/toolbar/loader.py +++ b/debug_toolbar/toolbar/loader.py @@ -5,7 +5,8 @@ from django.template.loader import render_to_string class DebugToolbar(object): - def __init__(self): + def __init__(self, request): + self.request = request self.panels = [] self.panel_list = [] self.content_list = [] @@ -33,7 +34,7 @@ class DebugToolbar(object): raise exceptions.ImproperlyConfigured, 'Toolbar Panel module "%s" does not define a "%s" class' % (panel_module, panel_classname) try: - panel_instance = panel_class() + panel_instance = panel_class(self.request) except: continue # Some problem loading panel |
