Prevent extra new-line character being introduced when starting chat

This commit is contained in:
drdev
2015-06-27 17:27:13 +00:00
parent ffe70e991e
commit 276144a62b
2 changed files with 3 additions and 3 deletions

View File

@@ -206,6 +206,6 @@ public enum FNetOverlay implements IOnlineChatInterface {
@Override
public void addMessage(final ChatMessage message) {
txtLog.append(message.getFormattedMessage());
txtLog.append("\n" + message.getFormattedMessage());
}
}

View File

@@ -37,8 +37,8 @@ public class ChatMessage {
public String getFormattedMessage() {
if (source == null) {
return String.format("%n[%s] %s", timestamp, message);
return String.format("[%s] %s", timestamp, message);
}
return String.format("%n[%s] %s: %s", timestamp, source, message);
return String.format("[%s] %s: %s", timestamp, source, message);
}
}