Fix chat import with non-normalized file names

This commit is contained in:
Ali
2021-03-11 17:11:10 +04:00
parent b7eb646bb3
commit dce1cc7776
2 changed files with 9 additions and 8 deletions

View File

@@ -764,7 +764,7 @@ struct OrderedHistoryViewEntries {
if self.lowerOrAtAnchor.count > 1 {
for i in 1 ..< self.lowerOrAtAnchor.count {
if self.lowerOrAtAnchor[i].index < self.lowerOrAtAnchor[i - 1].index {
assertionFailure()
//assertionFailure()
break
}
}
@@ -772,7 +772,7 @@ struct OrderedHistoryViewEntries {
if self.higherThanAnchor.count > 1 {
for i in 1 ..< self.higherThanAnchor.count {
if self.higherThanAnchor[i].index < self.higherThanAnchor[i - 1].index {
assertionFailure()
//assertionFailure()
break
}
}
@@ -796,7 +796,7 @@ struct OrderedHistoryViewEntries {
}
}
if fix {
assertionFailure()
//assertionFailure()
self.lowerOrAtAnchor.sort(by: { $0.index.id.id < $1.index.id.id })
self.higherThanAnchor.sort(by: { $0.index.id.id < $1.index.id.id })
}