mirror of
https://github.com/oxen-io/session-ios.git
synced 2023-12-13 21:30:14 +01:00
Fixed an issue where non-visible messages were causing their conversations to appear
Fixed a crash when trying to unsend a message
This commit is contained in:
parent
2053b6b0cd
commit
19eddd79a1
5 changed files with 20 additions and 5 deletions
1
Podfile
1
Podfile
|
@ -94,6 +94,7 @@ abstract_target 'GlobalDependencies' do
|
|||
target 'SessionUIKit' do
|
||||
pod 'GRDB.swift/SQLCipher'
|
||||
pod 'DifferenceKit'
|
||||
pod 'YYImage/libwebp', git: 'https://github.com/signalapp/YYImage'
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -212,6 +212,6 @@ SPEC CHECKSUMS:
|
|||
YYImage: f1ddd15ac032a58b78bbed1e012b50302d318331
|
||||
ZXingObjC: fdbb269f25dd2032da343e06f10224d62f537bdb
|
||||
|
||||
PODFILE CHECKSUM: f461937f78a0482496fea6fc4b2bb5d1351fe044
|
||||
PODFILE CHECKSUM: 5a4993725a7d48be883663a52df2a5de45d2d099
|
||||
|
||||
COCOAPODS: 1.11.3
|
||||
|
|
|
@ -1791,11 +1791,13 @@ extension ConversationVC:
|
|||
// Show a loading indicator
|
||||
Deferred {
|
||||
Future<Void, Error> { resolver in
|
||||
DispatchQueue.main.async {
|
||||
ModalActivityIndicatorViewController.present(fromViewController: viewController, canCancel: false) { _ in
|
||||
resolver(Result.success(()))
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.flatMap { _ in request }
|
||||
.subscribe(on: DispatchQueue.global(qos: .userInitiated))
|
||||
.receive(on: DispatchQueue.main)
|
||||
|
|
|
@ -175,7 +175,7 @@ public extension ConfigurationSyncJob {
|
|||
|
||||
static func enqueue(_ db: Database, publicKey: String) {
|
||||
// FIXME: Remove this once `useSharedUtilForUserConfig` is permanent
|
||||
guard SessionUtil.userConfigsEnabled else {
|
||||
guard SessionUtil.userConfigsEnabled(db) else {
|
||||
// If we don't have a userKeyPair (or name) yet then there is no need to sync the
|
||||
// configuration as the user doesn't fully exist yet (this will get triggered on
|
||||
// the first launch of a fresh install due to the migrations getting run and a few
|
||||
|
|
|
@ -282,10 +282,22 @@ public enum MessageReceiver {
|
|||
threadId: String,
|
||||
message: Message
|
||||
) throws {
|
||||
// When handling any non-typing indicator message we want to make sure the thread becomes
|
||||
// When handling any message type which has related UI we want to make sure the thread becomes
|
||||
// visible (the only other spot this flag gets set is when sending messages)
|
||||
switch message {
|
||||
case is ReadReceipt: break
|
||||
case is TypingIndicator: break
|
||||
case is ConfigurationMessage: break
|
||||
case is UnsendRequest: break
|
||||
|
||||
case let message as ClosedGroupControlMessage:
|
||||
// Only re-show a legacy group conversation if we are going to add a control text message
|
||||
switch message.kind {
|
||||
case .new, .encryptionKeyPair, .encryptionKeyPairRequest: return
|
||||
default: break
|
||||
}
|
||||
|
||||
fallthrough
|
||||
|
||||
default:
|
||||
// Only update the `shouldBeVisible` flag if the thread is currently not visible
|
||||
|
|
Loading…
Reference in a new issue