Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
AmbientTea committed Feb 21, 2025
1 parent acd3eb8 commit e0423cb
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions toolkit/partner-chains-cli/src/create_chain_spec/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use crate::permissioned_candidates::{ParsedPermissionedCandidatesKeys, Permissio
use crate::{config::config_fields, CmdRun};
use anyhow::{anyhow, Context};
use serde::de::DeserializeOwned;
use serde_json::Value as JValue;
use serde_json::{json, Value as JValue};
use sidechain_domain::UtxoId;

#[cfg(test)]
Expand Down Expand Up @@ -120,8 +120,15 @@ impl CreateChainSpecCmd {
let initial_authorities = config
.initial_permissioned_candidates_parsed
.iter()
.map(|c| serde_json::to_value((c.sidechain, c.session_keys())))
.collect::<Result<Vec<serde_json::Value>, _>>()?;
.map(|c| {
json!({
"Permissioned": {
"id": c.sidechain,
"keys": c.session_keys()
}
})
})
.collect::<Vec<serde_json::Value>>();
let initial_authorities = serde_json::Value::Array(initial_authorities);
Self::update_field(
&mut chain_spec,
Expand Down

0 comments on commit e0423cb

Please sign in to comment.