|
|
|
@ -271,7 +271,7 @@ public final class LokiAPI : NSObject {
|
|
|
|
|
if let lastMessage = rawMessages.last, let hashValue = lastMessage["hash"] as? String, let expirationDate = lastMessage["expiration"] as? Int {
|
|
|
|
|
setLastMessageHashValue(for: target, hashValue: hashValue, expirationDate: UInt64(expirationDate))
|
|
|
|
|
if UserDefaults.standard[.isUsingFullAPNs] {
|
|
|
|
|
LokiPushNotificationManager.acknowledgeDeliveryForMessage(with: hashValue, expiration: expirationDate, hexEncodedPublicKey: userHexEncodedPublicKey)
|
|
|
|
|
LokiPushNotificationManager.acknowledgeDelivery(forMessageWithHash: hashValue, expiration: expirationDate, hexEncodedPublicKey: userHexEncodedPublicKey)
|
|
|
|
|
}
|
|
|
|
|
} else if (!rawMessages.isEmpty) {
|
|
|
|
|
print("[Loki] Failed to update last message hash value from: \(rawMessages).")
|
|
|
|
|