mirror of
https://github.com/oxen-io/session-ios.git
synced 2023-12-13 21:30:14 +01:00
Fix crash
This commit is contained in:
parent
e6afbe2bfb
commit
e2e709e3d2
3 changed files with 3 additions and 3 deletions
|
@ -83,7 +83,7 @@ final class FriendRequestView : UIView {
|
|||
// MARK: Updating
|
||||
@objc private func handleFriendRequestStatusChangedNotification(_ notification: Notification) {
|
||||
let messageID = notification.object as! String
|
||||
guard messageID == message.uniqueId else { return }
|
||||
guard messageID == message.uniqueId && TSMessage.fetch(uniqueId: messageID) != nil else { return } // It's possible for the message to be deleted at this point
|
||||
message.reload()
|
||||
updateUI()
|
||||
}
|
||||
|
|
|
@ -739,7 +739,7 @@ ConversationColorName const kConversationColorName_Default = ConversationColorNa
|
|||
|
||||
// We want to remove any old incoming friend request messages which are pending
|
||||
if (interactionType == OWSInteractionType_IncomingMessage) {
|
||||
removeMessage = message.friendRequestStatus == LKMessageFriendRequestStatusPending;
|
||||
removeMessage = YES;
|
||||
} else {
|
||||
// Or if we're sending then remove any failed friend request messages
|
||||
TSOutgoingMessage *outgoingMessage = (TSOutgoingMessage *)message;
|
||||
|
|
|
@ -14,7 +14,7 @@ public final class LokiAPI : NSObject {
|
|||
private static let maxRetryCount: UInt = 8
|
||||
private static let defaultTimeout: TimeInterval = 20
|
||||
private static let longPollingTimeout: TimeInterval = 40
|
||||
private static let deviceLinkUpdateInterval: TimeInterval = 8 * 60
|
||||
private static let deviceLinkUpdateInterval: TimeInterval = 60
|
||||
private static let receivedMessageHashValuesKey = "receivedMessageHashValuesKey"
|
||||
private static let receivedMessageHashValuesCollection = "receivedMessageHashValuesCollection"
|
||||
private static var userIDScanLimit: UInt = 4096
|
||||
|
|
Loading…
Reference in a new issue