Clear pendingPreKeyRotation when an error occurs
This commit is contained in:
parent
9ffa21e4c2
commit
d2e09dcfd7
@ -431,8 +431,11 @@ public class MessageSender {
|
||||
// Only try to update the signed prekey; updating it is sufficient to
|
||||
// re-enable message sending.
|
||||
return Task {
|
||||
defer {
|
||||
// If this succeeds, or if we hit an error, allow another attempt.
|
||||
self.pendingPreKeyRotation.set(nil)
|
||||
}
|
||||
try await self.preKeyManager.rotateSignedPreKeysIfNeeded().value
|
||||
self.pendingPreKeyRotation.set(nil)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
|
||||
Loading…
Reference in New Issue
Block a user