Allow overrides for json-language-server settings (#20748)

Closes #20739

The JSON LSP adapter now merges user settings with cached settings, and
util::merge_json_value_into pushes array contents from source to target.
This commit is contained in:
teapo 2024-11-22 22:50:25 +00:00 committed by GitHub
parent 96854c68ea
commit c28f5b11f8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 22 additions and 5 deletions

View file

@ -149,6 +149,12 @@ pub fn merge_json_value_into(source: serde_json::Value, target: &mut serde_json:
}
}
(Value::Array(source), Value::Array(target)) => {
for value in source {
target.push(value);
}
}
(source, target) => *target = source,
}
}