diff --git a/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java b/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java index cc716cea4..48abb03fe 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java +++ b/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java @@ -436,6 +436,9 @@ public class ConferenceDetailsActivity extends XmppActivity implements OnConvers private void updateView() { invalidateOptionsMenu(); + if (mConversation == null) { + return; + } final MucOptions mucOptions = mConversation.getMucOptions(); final User self = mucOptions.getSelf(); String account; diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java index da7793276..feefbd105 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java +++ b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java @@ -2606,7 +2606,12 @@ public class ConversationFragment extends XmppFragment implements EditMessage.Ke service.sendChatState(conversation); } if (storeNextMessage()) { - runOnUiThread(() -> activity.onConversationsListItemUpdated()); + runOnUiThread(() -> { + if (activity == null) { + return; + } + activity.onConversationsListItemUpdated(); + }); } runOnUiThread(this::updateSendButton); }