1
0
Fork 0
mirror of https://github.com/morpheus65535/bazarr synced 2025-02-22 05:51:10 +00:00
bazarr/libs/flask_debugtoolbar/panels/config_vars.py
Moravčík, Marian 443607a33d More work
2019-12-16 14:58:10 +01:00

29 lines
607 B
Python

from flask import current_app
from flask_debugtoolbar.panels import DebugPanel
_ = lambda x: x
class ConfigVarsDebugPanel(DebugPanel):
"""
A panel to display all variables from Flask configuration
"""
name = 'ConfigVars'
has_content = True
def nav_title(self):
return _('Config')
def title(self):
return _('Config')
def url(self):
return ''
def content(self):
context = self.context.copy()
context.update({
'config': current_app.config,
})
return self.render('panels/config_vars.html', context)