From f7ec2ce33737150fac4b0db6164341c7fdb14626 Mon Sep 17 00:00:00 2001 From: inoussa Date: Tue, 16 Feb 2016 12:54:54 +0000 Subject: [PATCH] json serializer: do not raise exception when a scope is not found, while reading. git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@4508 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- wst/trunk/base_json_formatter.pas | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wst/trunk/base_json_formatter.pas b/wst/trunk/base_json_formatter.pas index d5651cd1c..09adf2e1a 100644 --- a/wst/trunk/base_json_formatter.pas +++ b/wst/trunk/base_json_formatter.pas @@ -942,7 +942,8 @@ begin stk := StackTop(); locNode := stk.FindNode(AScopeName); if not Assigned(locNode) then begin - Error(SERR_ScopeNotFound,[AScopeName]); + Result := -1; + exit; end; case locNode.JSONType() of jtObject : PushStack(locNode,stObject);