Only censor password in settings listing if the password is set

This commit is contained in:
Stein Magnus Jodal 2010-08-24 10:12:03 +02:00
parent 97122aca49
commit 5868506573

View File

@ -130,7 +130,7 @@ def list_settings_optparse_callback(*args):
lines = []
for (key, value) in sorted(settings.current.iteritems()):
default_value = settings.default.get(key)
if key.endswith('PASSWORD'):
if key.endswith('PASSWORD') and len(value):
value = u'********'
lines.append(u'%s:' % key)
lines.append(u' Value: %s' % repr(value))