From db2de5b85ac1ae099b91bae402d21d6ea36ef306 Mon Sep 17 00:00:00 2001 From: Aymeric Augustin Date: Sun, 24 Nov 2013 12:00:24 +0100 Subject: Make SHOW_TOOLBAR_CALLBACK a dotted path. Fix #473. --- docs/configuration.rst | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'docs') diff --git a/docs/configuration.rst b/docs/configuration.rst index a276aa3..c1fe65d 100644 --- a/docs/configuration.rst +++ b/docs/configuration.rst @@ -85,15 +85,13 @@ Toolbar options * ``SHOW_TOOLBAR_CALLBACK`` - Default: ``None`` + Default: 'debug_toolbar.middleware.show_toolbar' - If set to ``None``, the debug toolbar middleware will use its built-in - ``show_toolbar`` method for determining whether the toolbar should show or - not. The default checks are that ``DEBUG`` must be set to ``True``, the IP - of the request must be in ``INTERNAL_IPS``, and the request must no be an - AJAX request. You can provide your own method for displaying the toolbar - which contains your custom logic. This method should return ``True`` or - ``False``. + This is the dotted path to a function used for determining whether the + toolbar should show or not. The default checks are that ``DEBUG`` must be + set to ``True``, the IP of the request must be in ``INTERNAL_IPS``, and the + request must no be an AJAX request. You can provide your own function that + accepts a request in argument and returns ``True`` or ``False``. Panel options ~~~~~~~~~~~~~ -- cgit v1.2.3