From 1e4bd12c23a141c6c5a5a7743d0d32536c95c88c Mon Sep 17 00:00:00 2001 From: kske Date: Mon, 6 Jan 2020 15:00:44 +0200 Subject: [PATCH] Adjusted message creation to the updated MessageBuilder. --- src/main/java/envoy/client/ui/ChatWindow.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/envoy/client/ui/ChatWindow.java b/src/main/java/envoy/client/ui/ChatWindow.java index b839c4c..4f8b0dc 100644 --- a/src/main/java/envoy/client/ui/ChatWindow.java +++ b/src/main/java/envoy/client/ui/ChatWindow.java @@ -247,7 +247,9 @@ public class ChatWindow extends JFrame { if (!messageEnterTextArea.getText().isEmpty()) try { // Create message - final Message message = new MessageBuilder(localDB.getUser(), currentChat.getRecipient()).setText(messageEnterTextArea.getText()).build(); + final Message message = new MessageBuilder(localDB.getUser().getId(), currentChat.getRecipient().getId()) + .setText(messageEnterTextArea.getText()) + .build(); // Send message client.sendMessage(message);