From 5ec4e5339b0a7c8db652cf5f29b470c074b62dd9 Mon Sep 17 00:00:00 2001 From: sk Date: Fri, 11 Nov 2022 17:59:53 +0100 Subject: [PATCH] fix null pointer exception --- .../org/joinmastodon/android/fragments/ComposeFragment.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mastodon/src/main/java/org/joinmastodon/android/fragments/ComposeFragment.java b/mastodon/src/main/java/org/joinmastodon/android/fragments/ComposeFragment.java index 827331ba0..cd47805f6 100644 --- a/mastodon/src/main/java/org/joinmastodon/android/fragments/ComposeFragment.java +++ b/mastodon/src/main/java/org/joinmastodon/android/fragments/ComposeFragment.java @@ -668,7 +668,7 @@ public class ComposeFragment extends MastodonToolbarFragment implements OnBackPr if(!attachments.isEmpty()){ req.mediaIds=attachments.stream().map(a->a.serverAttachment.id).collect(Collectors.toList()); } - if(replyTo!=null || editingStatus.inReplyToId!=null){ + if(replyTo!=null || (editingStatus != null && editingStatus.inReplyToId!=null)){ req.inReplyToId=editingStatus!=null ? editingStatus.inReplyToId : replyTo.id; } if(!pollOptions.isEmpty()){