# HG changeset patch # User Marcin Kuzminski # Date 2017-11-11 15:43:45 # Node ID 05c6d5d5f0ac6d8c30f67fdb52501b4429b1a170 # Parent 565a855c19338d9929e603919ce789f0c2a36e59 ldap: fixed regression in extracting settings after library updates. - somehow we now got '' defaulted to None which changed the behaviour. diff --git a/rhodecode/authentication/base.py b/rhodecode/authentication/base.py --- a/rhodecode/authentication/base.py +++ b/rhodecode/authentication/base.py @@ -218,7 +218,10 @@ class RhodeCodeAuthPluginBase(object): else: plugin_settings = SettingsModel().get_all_settings() - return plugin_settings.get(full_name) or default + if full_name in plugin_settings: + return plugin_settings[full_name] + else: + return default def create_or_update_setting(self, name, value): """ diff --git a/rhodecode/authentication/plugins/auth_ldap.py b/rhodecode/authentication/plugins/auth_ldap.py --- a/rhodecode/authentication/plugins/auth_ldap.py +++ b/rhodecode/authentication/plugins/auth_ldap.py @@ -195,7 +195,7 @@ class AuthLdap(object): def __init__(self, server, base_dn, port=389, bind_dn='', bind_pass='', tls_kind='PLAIN', tls_reqcert='DEMAND', ldap_version=3, search_scope='SUBTREE', attr_login='uid', - ldap_filter=None): + ldap_filter=''): if ldap == Missing: raise LdapImportError("Missing or incompatible ldap library")