mirror of
https://github.com/kuitoi/kuitoi-Server.git
synced 2025-08-17 16:25:36 +00:00
FIX _identifiers and e | e
This commit is contained in:
parent
f145048cc1
commit
50c12f4b5c
@ -634,7 +634,9 @@ class Client:
|
||||
self.log.info(f"{message}" if to_all else f"{self.nick}: {msg}")
|
||||
await self._send(f"C:{message}", to_all=to_all, to_self=to_self, writer=writer)
|
||||
need_send = False
|
||||
except KeyError | AttributeError:
|
||||
except KeyError:
|
||||
self.log.error(i18n.client_event_invalid_data.format(ev_data))
|
||||
except AttributeError:
|
||||
self.log.error(i18n.client_event_invalid_data.format(ev_data))
|
||||
if need_send:
|
||||
if config.Options['log_chat']:
|
||||
|
@ -53,6 +53,8 @@ class TCPServer:
|
||||
client.roles = res["roles"]
|
||||
client._guest = res["guest"]
|
||||
client._identifiers = {k: v for s in res["identifiers"] for k, v in [s.split(':')]}
|
||||
if not client._identifiers.get("ip"):
|
||||
client._identifiers["ip"] = client._addr[0]
|
||||
# noinspection PyProtectedMember
|
||||
client._update_logger()
|
||||
except Exception as e:
|
||||
|
Loading…
x
Reference in New Issue
Block a user