added format to replace string variable for logging

This commit is contained in:
2022-05-23 19:28:20 -04:00
parent 6dd80c46db
commit 72061c6ed4

View File

@@ -116,7 +116,7 @@ for seafileUser in seafileUsers:
continue
else:
logger.debug("User: {0} - Active: {1}".format(seafileUser['email'], bool(seafileUser['is_active'])))
logger.debug("Checking if {0} user has an email, is active, and is in the seafile group")
logger.debug("Checking if {0} user has an email, is active, and is in the seafile group".format(seafileUser['email'])
ldap.search(ldapBase, '(&(mail={0})(!(userAccountControl:1.2.840.113556.1.4.803:=2))({1}))'.format(seafileUser['email'], ldapFilter), attributes=['*'])
count = len(ldap.entries)
logger.debug("Found {0} LDAP user.".format(count))