1
0
mirror of https://github.com/etesync/server synced 2024-12-27 09:48:24 +00:00

fix: Python files

This commit is contained in:
Alejandro 2023-07-25 00:35:10 +02:00 committed by Tom Hacohen
parent 55d3fb7e8e
commit 4293acb3a3
2 changed files with 3 additions and 3 deletions

View File

@ -136,7 +136,7 @@ async def redis_connector(websocket: WebSocket, ticket_model: TicketInner, user:
for task in pending:
task.cancel()
if receive in done:
# Web socket should never receieve any data
# Web socket should never receive any data
await websocket.close(code=status.WS_1008_POLICY_VIOLATION)
return

View File

@ -54,7 +54,7 @@ class LDAPConnection:
try:
self.__ldap_connection.simple_bind_s(ldap_setting("BIND_DN", ""), password)
except ldap.LDAPError as err:
logging.error(f"LDAP Error occuring during bind: {err.desc}")
logging.error(f"LDAP Error occurring during bind: {err.desc}")
def __is_cache_valid(self, username):
"""Returns True if the cache entry is still valid. Returns False otherwise."""
@ -85,7 +85,7 @@ class LDAPConnection:
# we may expect ldap.NO_RESULTS_RETURNED, but not any other error
return False
except ldap.LDAPError as err:
logging.error(f"Error occured while performing an LDAP query: {err.desc}")
logging.error(f"Error occurred while performing an LDAP query: {err.desc}")
return False
if len(result) == 1: