@@ 16,5 16,6 @@ namespace NosSmooth.Packets.Errors;
/// <param name="Converter">The converter that could not deserialize the parameter.</param>
/// <param name="PropertyName">The name of the property.</param>
/// <param name="Result">The underlying result.</param>
-public record PacketParameterSerializerError(ITypeConverter Converter, string PropertyName, IResult Result)
- : ResultError($"There was an error deserializing property {PropertyName} in converter {Converter.GetType().FullName}");>
\ No newline at end of file
+/// <param name="Reason">The reason for the error, if known.</param>
+public record PacketParameterSerializerError(ITypeConverter Converter, string PropertyName, IResult Result, string? Reason = null)
+ : ResultError($"There was an error deserializing property {PropertyName} in converter {Converter.GetType().FullName}{(Reason is not null ? (", reason: " + Reason) : string.Empty)}");<
\ No newline at end of file