File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
src/FSharp.Data.GraphQL.Shared Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -294,17 +294,18 @@ module SchemaDefinitions =
294294
295295 /// Tries to resolve AST query input to URI.
296296 let coerceUriInput =
297+ let destinationType = " URI"
297298 function
298299 | Variable e when e.ValueKind = JsonValueKind.String ->
299300 match Uri.TryCreate( e.GetString(), UriKind.RelativeOrAbsolute) with
300301 | true , uri -> Ok uri
301- | false , _ -> Error [{ new IGQLError with member _.Message = $ " Cannot deserialize '{e.GetRawText()}' into URI " }]
302- | Variable e -> e.GetDeserializeError " URI "
302+ | false , _ -> e.GetDeserializeError destinationType
303+ | Variable e -> e.GetDeserializeError destinationType
303304 | InlineConstant ( StringValue s) ->
304305 match Uri.TryCreate( s, UriKind.RelativeOrAbsolute) with
305306 | true , uri -> Ok uri
306- | false , _ -> Error [{ new IGQLError with member _.Message = $ " Cannot parse '{s}' into URI " }]
307- | InlineConstant value -> value.GetCoerceError " URI "
307+ | false , _ -> getParseError destinationType s
308+ | InlineConstant value -> value.GetCoerceError destinationType
308309
309310 /// Tries to resolve AST query input to DateTimeOffset.
310311 let coerceDateTimeOffsetInput =
You can’t perform that action at this time.
0 commit comments