Skip to content
This repository was archived by the owner on Apr 27, 2019. It is now read-only.

Commit 35ed740

Browse files
committed
Fixed trace logging error that would dump a bunch of output on a server broadcast.
1 parent 46e036d commit 35ed740

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

server.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,8 @@ def send_chat_message(self, text, channel=0, world='', name=''):
403403
for line in lines:
404404
self.send_chat_message(line)
405405
return
406-
logger.trace("Calling send_chat_message from player %s on channel %d on world '%s' with reported username of %s with message: %s", self.player.name, channel, world, name, text)
406+
if self.player is not None:
407+
logger.trace("Calling send_chat_message from player %s on channel %d on world '%s' with reported username of %s with message: %s", self.player.name, channel, world, name, text)
407408
chat_data = packets.chat_received().build(Container(chat_channel=channel,
408409
world=world,
409410
client_id=0,

0 commit comments

Comments
 (0)