mirror of
https://github.com/kakwa/ldapcherry
synced 2025-02-16 15:43:19 +01:00
fix error if no ppolicy module
This commit is contained in:
parent
0d045576b2
commit
cd13bf5d22
@ -177,7 +177,11 @@ class LdapCherry(object):
|
|||||||
pp = __import__(module, globals(), locals(), ['PPolicy'], -1)
|
pp = __import__(module, globals(), locals(), ['PPolicy'], -1)
|
||||||
except:
|
except:
|
||||||
raise BackendModuleLoadingFail(module)
|
raise BackendModuleLoadingFail(module)
|
||||||
self.ppolicy = pp.PPolicy(config['ppolicy'], cherrypy.log)
|
if 'ppolicy' in config:
|
||||||
|
ppcfg = config['ppolicy']
|
||||||
|
else:
|
||||||
|
ppcfg = {}
|
||||||
|
self.ppolicy = pp.PPolicy(ppcfg, cherrypy.log)
|
||||||
|
|
||||||
def _init_auth(self, config):
|
def _init_auth(self, config):
|
||||||
""" Init authentication
|
""" Init authentication
|
||||||
|
Loading…
x
Reference in New Issue
Block a user