From d61fd85ea6900ab0da9c03e805e6ec16cccc7c1a Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Thu, 30 Mar 2017 15:43:07 +0200 Subject: [PATCH] Item("") now returns the value itself (can be used to get all keys of specific object). --- library/configuration/src/json_config.e | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/library/configuration/src/json_config.e b/library/configuration/src/json_config.e index 339c38f..8e3a5d9 100644 --- a/library/configuration/src/json_config.e +++ b/library/configuration/src/json_config.e @@ -148,7 +148,9 @@ feature -- Access -- `k' can be a single name such as "foo", -- or a qualified name such as "foo.bar" (assuming that "foo" is associated with a JSON object). do - if attached json_value as obj then + if k.is_empty then + Result := json_value + elseif attached json_value as obj then Result := object_json_value (obj, k.to_string_32) end end