correction creation folder annee qui n'existe pas

This commit is contained in:
Romain Beuque 2014-09-01 00:27:25 +02:00
parent 7686092293
commit 966da7c992

View File

@ -93,7 +93,7 @@ class MemberAddController(AuthenticatedRestController):
#endif #endif
def year_directory_exists(year): def year_directory_exists(year):
search = self.user.ldap_bind.search_s(ldap_config.username_base_dn + residence_dn,ldap.SCOPE_SUBTREE,"(ou="+str(year)+")") search = self.user.ldap_bind.search(ldap_config.username_base_dn + residence_dn,"(ou="+str(year)+")")
if len(search) == 0: if len(search) == 0:
print "[LOG]Year "+str(year)+" directory does not exist. Creating." print "[LOG]Year "+str(year)+" directory does not exist. Creating."
directory_attrs = { directory_attrs = {