diff --git a/libs/data.py b/libs/data.py index e131748..c898aca 100644 --- a/libs/data.py +++ b/libs/data.py @@ -156,18 +156,14 @@ class Yuuki_Data: def _local_query(self, query_data): if type(query_data) is list: result = self.Data - query_len = len(query_data) - source_data = self.Data + query_len = len(query_data) - 1 for count, key in enumerate(query_data): - if key in source_data: - if count < (query_len - 1): - if type(source_data.get(key)) is dict: - source_data = source_data.get(key) - else: + if key in result: + if count < query_len: + if type(result.get(key)) is not dict: result = 1 break - else: - result = source_data.get(key) + result = result.get(key) else: result = 2 break diff --git a/libs/data_mds.py b/libs/data_mds.py index a452efa..a9a0ace 100644 --- a/libs/data_mds.py +++ b/libs/data_mds.py @@ -50,18 +50,14 @@ def query(query_data, null=None): try: if type(switch_data) is dict and type(query_data) is list: result = switch_data - query_len = len(query_data) - source_data = switch_data + query_len = len(query_data) - 1 for count, key in enumerate(query_data): - if key in source_data: - if count < (query_len - 1): - if type(source_data.get(key)) is dict: - source_data = source_data.get(key) - else: + if key in result: + if count < query_len: + if type(result.get(key)) is not dict: result = 1 #"unknown_type" + type(source_data.get(key)) break - else: - result = source_data.get(key) + result = result.get(key) else: result = 2 #"unknown_key" break diff --git a/libs/yuuki.py b/libs/yuuki.py index 0c9f772..a895582 100644 --- a/libs/yuuki.py +++ b/libs/yuuki.py @@ -27,7 +27,7 @@ class Yuuki_Settings: config = { "name": "Yuuki", - "version": "v6.5.2", + "version": "v6.5.2_RC1", "version_check": True, "project_url": "https://tinyurl.com/syb-yuuki", "man_page": "https://tinyurl.com/yuuki-manual",