mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-04 01:20:12 +00:00
Make BugReportService reportUrl optional (#4195)
This commit is contained in:
@@ -140,7 +140,7 @@ class BugReportService: NSObject, BugReportServiceProtocol {
|
|||||||
decoder.keyDecodingStrategy = .convertFromSnakeCase
|
decoder.keyDecodingStrategy = .convertFromSnakeCase
|
||||||
let uploadResponse = try decoder.decode(SubmitBugReportResponse.self, from: data)
|
let uploadResponse = try decoder.decode(SubmitBugReportResponse.self, from: data)
|
||||||
|
|
||||||
if !uploadResponse.reportUrl.isEmpty {
|
if !(uploadResponse.reportUrl?.isEmpty ?? false) {
|
||||||
lastCrashEventID = nil
|
lastCrashEventID = nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ struct BugReport: Equatable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
struct SubmitBugReportResponse: Decodable {
|
struct SubmitBugReportResponse: Decodable {
|
||||||
var reportUrl: String
|
var reportUrl: String?
|
||||||
}
|
}
|
||||||
|
|
||||||
enum BugReportServiceError: LocalizedError {
|
enum BugReportServiceError: LocalizedError {
|
||||||
|
|||||||
Reference in New Issue
Block a user