From 1ddfdb34b1e158f4de790b63385b4e9cbebdbefe Mon Sep 17 00:00:00 2001 From: Cerapter Date: Thu, 20 Sep 2018 18:41:40 +0200 Subject: [PATCH] Fixed a small bug regarding music changes while shownamed. --- server/aoprotocol.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/aoprotocol.py b/server/aoprotocol.py index 18f688b..1bf9001 100644 --- a/server/aoprotocol.py +++ b/server/aoprotocol.py @@ -627,10 +627,10 @@ class AOProtocol(asyncio.Protocol): if self.client.area.jukebox: showname = '' if len(args) > 2: - if len(args[2]) > 0 and not self.client.area.showname_changes_allowed: + showname = args[2] + if len(showname) > 0 and not self.client.area.showname_changes_allowed: self.client.send_host_message("Showname changes are forbidden in this area!") return - showname = args[2] self.client.area.add_jukebox_vote(self.client, name, length, showname) logger.log_server('[{}][{}]Added a jukebox vote for {}.'.format(self.client.area.abbreviation, self.client.get_char_name(), name), self.client) else: