mirror of
https://github.com/oxen-io/session-ios.git
synced 2023-12-13 21:30:14 +01:00
* Add debug UI tools for clearing and logging the profile whitelist.
* Auto-add new contact threads to profile whitelist when local user sends first message to that thread. * Ensure dynamic interactions have a non-negative timestamp even if the conversation was empty. * Only call updateMessageMappingRangeOptions _after_ beginLongLivedReadTransaction and updating messageMappings. * Improve documentation around how to avoid corrupt mappings in conversation view. * Fix edge cases around large initial range sizes. * Always treat dynamic interactions as read. * Rebuild the “unseen” database views to remove dynamic interactions (see above). // FREEBIE
This commit is contained in:
parent
d476bc286d
commit
622c0c3f5f
2 changed files with 4 additions and 4 deletions
|
@ -1141,9 +1141,9 @@ NS_ASSUME_NONNULL_BEGIN
|
|||
- (NSUInteger)unreadMessagesCountExcept:(TSThread *)thread {
|
||||
__block NSUInteger numberOfItems;
|
||||
[self.dbConnection readWithBlock:^(YapDatabaseReadTransaction *transaction) {
|
||||
numberOfItems = [[transaction ext:TSUnreadDatabaseViewExtensionName] numberOfItemsInAllGroups];
|
||||
numberOfItems =
|
||||
numberOfItems - [[transaction ext:TSUnreadDatabaseViewExtensionName] numberOfItemsInGroup:thread.uniqueId];
|
||||
id databaseView = [transaction ext:TSUnreadDatabaseViewExtensionName];
|
||||
OWSAssert(databaseView);
|
||||
numberOfItems = ([databaseView numberOfItemsInAllGroups] - [databaseView numberOfItemsInGroup:thread.uniqueId]);
|
||||
}];
|
||||
|
||||
return numberOfItems;
|
||||
|
|
|
@ -125,7 +125,7 @@ NSString *const TSSecondaryDevicesDatabaseViewExtensionName = @"TSSecondaryDevic
|
|||
|
||||
[self registerMessageDatabaseViewWithName:TSUnreadDatabaseViewExtensionName
|
||||
viewGrouping:viewGrouping
|
||||
version:@"2"
|
||||
version:@"1"
|
||||
async:NO];
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue