Only clean up messages while active

// FREEBIE
This commit is contained in:
Michael Kirk 2018-05-17 10:53:58 -04:00
parent 4080545d85
commit c0ddcc7919

View file

@ -364,6 +364,10 @@ void AssertIsOnDisappearingMessagesQueue()
}
dispatch_async(OWSDisappearingMessagesJob.serialQueue, ^{
if (!CurrentAppContext().isMainAppAndActive) {
DDLogInfo(@"%@ Ignoring fallbacktimer for app which is not main and active.", self.logTag);
return;
}
NSUInteger deletedCount = [self runLoop];
// Normally deletions should happen via the disappearanceTimer, to make sure that they're prompt.