aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/pixart/messenger
diff options
context:
space:
mode:
authorChristian Schneppe <christian@pix-art.de>2019-06-08 14:18:47 +0200
committerChristian Schneppe <christian@pix-art.de>2019-06-08 14:18:47 +0200
commited244ed74bc611ffbb3fcc052338333ac603a5f4 (patch)
tree6e20ac2dc3c6ac6eac5192547d06e7304893020b /src/main/java/de/pixart/messenger
parent4ba1553eb76e25be83ec701d25e879fb9fca9bfc (diff)
fixed some NPE
Diffstat (limited to 'src/main/java/de/pixart/messenger')
-rw-r--r--src/main/java/de/pixart/messenger/ui/ConversationFragment.java9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/main/java/de/pixart/messenger/ui/ConversationFragment.java b/src/main/java/de/pixart/messenger/ui/ConversationFragment.java
index f0ea6113b..ae0b1781e 100644
--- a/src/main/java/de/pixart/messenger/ui/ConversationFragment.java
+++ b/src/main/java/de/pixart/messenger/ui/ConversationFragment.java
@@ -2863,9 +2863,12 @@ public class ConversationFragment extends XmppFragment implements EditMessage.Ke
if (status == Account.State.ONLINE && conversation.setOutgoingChatState(Config.DEFAULT_CHATSTATE)) {
service.sendChatState(conversation);
}
- if (storeNextMessage()) {
- runOnUiThread(() -> activity.onConversationsListItemUpdated());
- }
+ runOnUiThread(() -> {
+ if (activity == null) {
+ return;
+ }
+ activity.onConversationsListItemUpdated();
+ });
runOnUiThread(this::updateSendButton);
}