mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 06:55:59 +00:00
Avoid race conditions between the home screen's crash alert and Sentry's onLastRunStatusDetermined
By converting the `lastCrashEventID` to a publisher that the VM can just listen to instead of relying on start to match a pre-set event
This commit is contained in:
@@ -17,5 +17,6 @@ extension BugReportServiceMock {
|
||||
self.init()
|
||||
|
||||
isEnabled = configuration.isEnabled
|
||||
lastCrashEventIDSubject = .init(nil)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1809,12 +1809,11 @@ nonisolated class BugReportServiceMock: BugReportServiceProtocol, @unchecked Sen
|
||||
set(value) { underlyingIsEnabled = value }
|
||||
}
|
||||
nonisolated(unsafe) var underlyingIsEnabled: Bool!
|
||||
var crashedLastRun: Bool {
|
||||
get { return underlyingCrashedLastRun }
|
||||
set(value) { underlyingCrashedLastRun = value }
|
||||
var lastCrashEventIDSubject: CurrentValueSubject<String?, Never> {
|
||||
get { return underlyingLastCrashEventIDSubject }
|
||||
set(value) { underlyingLastCrashEventIDSubject = value }
|
||||
}
|
||||
nonisolated(unsafe) var underlyingCrashedLastRun: Bool!
|
||||
nonisolated(unsafe) var lastCrashEventID: String?
|
||||
nonisolated(unsafe) var underlyingLastCrashEventIDSubject: CurrentValueSubject<String?, Never>!
|
||||
|
||||
//MARK: - submitBugReport
|
||||
|
||||
|
||||
Reference in New Issue
Block a user