referrerpolicy=no-referrer-when-downgrade

Function sc_chain_spec::update_code_in_json_chain_spec

source ·
pub fn update_code_in_json_chain_spec(
    chain_spec: &mut Value,
    code: &[u8],
) -> bool
Expand description

This function updates the code in given chain spec.

Function support updating the runtime code in provided JSON chain spec blob. Genesis::Raw and Genesis::RuntimeGenesis formats are supported.

If update was successful true is returned, otherwise false. Chain spec JSON is modified in place.