Mark "attempting out" messages as "unsent" on app launch. #113
Conversation
@@ -554,6 +560,9 @@ - (void)handleMessageSentLocally:(TSOutgoingMessage *)message | |||
{ | |||
[self saveMessage:message withState:TSOutgoingMessageStateSent]; | |||
if (message.shouldSyncTranscript) { | |||
// TODO: I suspect we shouldn't optimistically set hasSyncedTranscript. | |||
// We could set this in a success handler for [sendSyncTranscriptForMessage:]. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@michaelkirk thoughts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree it's weird to optimistically set it like this. But make sure than any changes don't result in it being sent once per group recipient.
E.g. if I'm in a group with Alice, Bob, and Georgia, I should still send only one sync message.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've opened a new issue where we can track/discuss this issue: signalapp/Signal-iOS#1761
PTAL @michaelkirk |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -554,6 +560,9 @@ - (void)handleMessageSentLocally:(TSOutgoingMessage *)message | |||
{ | |||
[self saveMessage:message withState:TSOutgoingMessageStateSent]; | |||
if (message.shouldSyncTranscript) { | |||
// TODO: I suspect we shouldn't optimistically set hasSyncedTranscript. | |||
// We could set this in a success handler for [sendSyncTranscriptForMessage:]. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree it's weird to optimistically set it like this. But make sure than any changes don't result in it being sent once per group recipient.
E.g. if I'm in a group with Alice, Bob, and Georgia, I should still send only one sync message.
c6fdcbb
to
821c96c
Compare
See: signalapp/Signal-iOS#1035
I tried to use
OWSDisappearingMessagesJob
andOWSDisappearingMessagesFinder
as a model.PTAL @michaelkirk