From 7398424f3ba5c36ffab9a92ddd10cb3cf8eb42e0 Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Fri, 3 Jun 2016 19:24:11 +0200 Subject: [PATCH] trim nick from bookmark before checking if it's empty --- src/main/java/eu/siacs/conversations/entities/MucOptions.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/eu/siacs/conversations/entities/MucOptions.java b/src/main/java/eu/siacs/conversations/entities/MucOptions.java index d08483703..c71afd99e 100644 --- a/src/main/java/eu/siacs/conversations/entities/MucOptions.java +++ b/src/main/java/eu/siacs/conversations/entities/MucOptions.java @@ -504,8 +504,8 @@ public class MucOptions { public String getProposedNick() { if (conversation.getBookmark() != null && conversation.getBookmark().getNick() != null - && !conversation.getBookmark().getNick().isEmpty()) { - return conversation.getBookmark().getNick(); + && !conversation.getBookmark().getNick().trim().isEmpty()) { + return conversation.getBookmark().getNick().trim(); } else if (!conversation.getJid().isBareJid()) { return conversation.getJid().getResourcepart(); } else {