From 582085cd8a53223237a9c232085abcbc42d291cc Mon Sep 17 00:00:00 2001 From: Trygve Aaberge Date: Wed, 17 Jun 2020 23:41:25 +0200 Subject: Don't set label when changing buffer name This caused a bug where the short_name got a double prefix, because the label was set to the short_name which wasn't changed. --- wee_slack.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'wee_slack.py') diff --git a/wee_slack.py b/wee_slack.py index b1f7a87..9b2ad57 100644 --- a/wee_slack.py +++ b/wee_slack.py @@ -834,7 +834,8 @@ def reconnect_callback(*args): def buffer_renamed_cb(data, signal, current_buffer): channel = EVENTROUTER.weechat_controller.buffers.get(current_buffer) if channel and not channel.buffer_rename_in_progress: - channel.label = w.buffer_get_string(channel.channel_buffer, "short_name") + if not w.buffer_get_string(channel.channel_buffer, "old_full_name"): + channel.label = w.buffer_get_string(channel.channel_buffer, "short_name") channel.rename() return w.WEECHAT_RC_OK -- cgit