Unwanted Optional handling removed

This commit is contained in:
Danish Phiroz 2024-10-23 11:22:33 -04:00
parent 0fd00d05db
commit 5ab30a1930

View File

@ -94,7 +94,7 @@ public struct ModelRegistry {
case .decoderErrorUnexpectedType(let actualType, let expectedType, let identifer, let codingKey, let codingPath):
errorObject.title = "Decoder Error: Model Type Unexpected"
let codingPathConcat = codingPath?.compactMap { $0.stringValue }.joined(separator: " ") ?? ""
errorObject.messageToLog = "Actual Type: \(actualType ?? "") Expected Type: \(expectedType ?? "")" + (identifer ?? "") + (codingKey?.stringValue ?? "") + codingPathConcat
errorObject.messageToLog = "Actual Type: \(actualType) Expected Type: \(expectedType)" + (identifer) + (codingKey?.stringValue ?? "") + codingPathConcat
case .handlerNotMapped(let identifer, let categoryName):
errorObject.title = "Handler Not Mapped"
errorObject.messageToLog = (identifer ?? "") + (categoryName ?? "")