From fae34e8be4822c297ddc207129e70be269e510ac Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Mon, 11 Aug 2014 22:16:11 +0200 Subject: [PATCH] correctly detect when no name is provided for bookmarks --- src/config.py | 2 +- src/roster_window.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/config.py b/src/config.py index b4f399274..006e4e4a8 100644 --- a/src/config.py +++ b/src/config.py @@ -3185,7 +3185,7 @@ class ManageBookmarksWindow: None, None, None, None]) for bookmark in gajim.connections[account].bookmarks: - if bookmark['name'] == '': + if not bookmark['name']: # No name was given for this bookmark. # Use the first part of JID instead... name = bookmark['jid'].split("@")[0] diff --git a/src/roster_window.py b/src/roster_window.py index cd6c97ff4..682ffc65e 100644 --- a/src/roster_window.py +++ b/src/roster_window.py @@ -6109,7 +6109,7 @@ class RosterWindow: for bookmark in gajim.connections[account].bookmarks: name = bookmark['name'] - if bookmark['name'] == '': + if not name: # No name was given for this bookmark. # Use the first part of JID instead... name = bookmark['jid'].split("@")[0]