From e5ed4c1b7d366c78881ad65419475a9dc40e91b5 Mon Sep 17 00:00:00 2001 From: Timothee Cour Date: Sun, 15 Dec 2019 14:04:06 -0800 Subject: [PATCH] fix json regression D20191212T144944 (#12902) [backport] --- lib/pure/json.nim | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/pure/json.nim b/lib/pure/json.nim index 5b6cf0856..319a7b7ff 100644 --- a/lib/pure/json.nim +++ b/lib/pure/json.nim @@ -1055,6 +1055,7 @@ when defined(nimFixedForwardGeneric): jsonPath.setLen originalJsonPathLen proc initFromJson[T](dst: var ref T; jsonNode: JsonNode; jsonPath: var string) = + verifyJsonKind(jsonNode, {JObject, JNull}, jsonPath) if jsonNode.kind == JNull: dst = nil else: