Skip to content

Commit

Permalink
fix: Silence some warning for sentry logs casting
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilippeWeidmann committed Apr 24, 2024
1 parent c1122fb commit dac975b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions Mail/Views/Thread/WebView/WebViewModel+MessageHandler.swift
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ extension WebViewModel: WKScriptMessageHandler {
SentrySDK.capture(message: "After zooming the mail it can still scroll.") { scope in
scope.setTags(["messageUid": data["messageId"] as? String ?? ""])
scope.setExtras([
"clientWidth": data["clientWidth"],
"scrollWidth": data["scrollWidth"]
"clientWidth": data["clientWidth"] as Any,
"scrollWidth": data["scrollWidth"] as Any
])
}
}
Expand All @@ -69,9 +69,9 @@ extension WebViewModel: WKScriptMessageHandler {
SentrySDK.capture(message: "JavaScript returned an error when displaying an email.") { scope in
scope.setTags(["messageUid": data["messageId"] ?? ""])
scope.setExtras([
"errorName": data["errorName"],
"errorMessage": data["errorMessage"],
"errorStack": data["errorStack"]
"errorName": data["errorName"] as Any,
"errorMessage": data["errorMessage"] as Any,
"errorStack": data["errorStack"] as Any
])
}
}
Expand Down
2 changes: 1 addition & 1 deletion MailCore/Utils/SentryDebug.swift
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ public enum SentryDebug {
"Seen": ["Expected": actualSeen, "Actual": liveMessage.seen],
"Folder": ["id": message.folder?.remoteId ?? "nil",
"name": message.folder?.matomoName ?? "nil",
"last update": message.folder?.lastUpdate,
"last update": message.folder?.lastUpdate as Any,
"cursor": message.folder?.cursor ?? "nil"]],
key: "Message context")
}
Expand Down

0 comments on commit dac975b

Please sign in to comment.