Last Updated: February 25, 2016
·
10.21K
· katylava

Disable django-debug-toolbar when DEBUG = True

Took me some digging to find this, so thought I'd share.

In your settings file, you have to add a callback function to the debug_toolbar config dict, like so:

DEBUG_TOOLBAR_CONFIG = {
    'SHOW_TOOLBAR_CALLBACK': lambda r: False,  # disables it
    # '...
}