Function sc_chain_spec::json_patch::merge
source · pub fn merge(a: &mut Value, b: Value)
Expand description
Recursively merges two JSON objects, a
and b
, into a single object.
If a key exists in both objects, the value from b
will override the value from a
.
If a key exists in b
with a null
value, it will be removed from a
.
If a key exists only in b
and not in a
, it will be added to a
.
§Arguments
a
- A mutable reference to the target JSON object to merge into.b
- The JSON object to merge witha
.