Interpret Return-Receipt-To as read receipt request

This commit is contained in:
M66B 2023-09-08 18:34:06 +02:00
parent 67abc81566
commit 1f1a2ac86e
1 changed files with 3 additions and 0 deletions

View File

@ -545,6 +545,7 @@ public class MessageHelper {
}
// https://tools.ietf.org/html/rfc3798
// https://en.wikipedia.org/wiki/Return_receipt
if (receipt_type == 0 || receipt_type == 2) {
// Read receipt
imessage.addHeader("Disposition-Notification-To", to);
@ -2094,6 +2095,8 @@ public class MessageHelper {
Address[] receipt = getAddressHeader("Disposition-Notification-To");
if (receipt == null || receipt.length == 0)
receipt = getAddressHeader("Read-Receipt-To");
if (receipt == null || receipt.length == 0)
receipt = getAddressHeader("Return-Receipt-To");
if (receipt == null || receipt.length == 0)
receipt = getAddressHeader("X-Confirm-Reading-To");
return receipt;