Skip to content

Commit 494e98b

Browse files
authored
Handling list merge in _utils.merge_dicts(). (#38)
1 parent cf4eaad commit 494e98b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pylsp/_utils.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,8 @@ def _merge_dicts_(a, b):
125125
if key in a and key in b:
126126
if isinstance(a[key], dict) and isinstance(b[key], dict):
127127
yield (key, dict(_merge_dicts_(a[key], b[key])))
128+
elif isinstance(a[key], list) and isinstance(b[key], list):
129+
yield (key, list(set(a[key] + b[key])))
128130
elif b[key] is not None:
129131
yield (key, b[key])
130132
else:

0 commit comments

Comments
 (0)