1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-27 02:07:12 +00:00

Prevent null References

This commit is contained in:
M66B 2022-07-23 13:06:02 +02:00
parent fd6b9b101f
commit 7407a05d28

View file

@ -4858,7 +4858,10 @@ public class FragmentCompose extends FragmentBase {
// https://tools.ietf.org/html/rfc5322#section-3.6.4
// The "References:" field will contain the contents of the parent's "References:" field (if any)
// followed by the contents of the parent's "Message-ID:" field (if any).
data.draft.references = (ref.references == null ? "" : ref.references + " ") + ref.msgid;
String refs = (ref.references == null ? "" : ref.references);
if (!TextUtils.isEmpty(ref.msgid))
refs = (TextUtils.isEmpty(refs) ? ref.msgid : refs + " " + ref.msgid);
data.draft.references = refs;
data.draft.inreplyto = ref.msgid;
data.draft.thread = ref.thread;