mirror of
https://github.com/deltachat/deltachat-android.git
synced 2025-10-06 03:49:58 +02:00
avoid crash in orphan info messages from webxdc
This commit is contained in:
parent
ad1159c05c
commit
3e21f9be4d
2 changed files with 5 additions and 2 deletions
|
@ -747,7 +747,10 @@ public class ConversationFragment extends MessageSelectorFragment
|
||||||
DozeReminder.dozeReminderTapped(getContext());
|
DozeReminder.dozeReminderTapped(getContext());
|
||||||
}
|
}
|
||||||
else if(messageRecord.getInfoType() == DcMsg.DC_INFO_WEBXDC_INFO_MESSAGE) {
|
else if(messageRecord.getInfoType() == DcMsg.DC_INFO_WEBXDC_INFO_MESSAGE) {
|
||||||
WebxdcActivity.openWebxdcActivity(getContext(), messageRecord.getParent(), messageRecord.getWebxdcHref());
|
if (messageRecord.getParent() != null) {
|
||||||
|
// if the parent webxdc message still exists
|
||||||
|
WebxdcActivity.openWebxdcActivity(getContext(), messageRecord.getParent(), messageRecord.getWebxdcHref());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
String self_mail = dcContext.getConfig("configured_mail_user");
|
String self_mail = dcContext.getConfig("configured_mail_user");
|
||||||
|
|
|
@ -106,7 +106,7 @@ public class WebxdcActivity extends WebViewActivity implements DcEventCenter.DcE
|
||||||
openWebxdcActivity(context, instance, "");
|
openWebxdcActivity(context, instance, "");
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void openWebxdcActivity(Context context, DcMsg instance, String href) {
|
public static void openWebxdcActivity(Context context, @NonNull DcMsg instance, String href) {
|
||||||
openWebxdcActivity(context, instance.getId(), false, href);
|
openWebxdcActivity(context, instance.getId(), false, href);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue