Skip to content

Commit

Permalink
fix(node): fix update-config when reward.conf does not exist (#3290)
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewbattat authored Dec 23, 2024
1 parent 8c82f7f commit bc83b42
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions rs/ic_os/config/src/update_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -189,10 +189,12 @@ fn read_nns_conf(config_dir: &Path) -> Result<Vec<Url>> {

fn read_reward_conf(config_dir: &Path) -> Result<Option<String>> {
let reward_conf_path = config_dir.join("reward.conf");
let conf_map = read_conf_file(&reward_conf_path)?;
if !reward_conf_path.exists() {
return Ok(None);
}

let conf_map = read_conf_file(&reward_conf_path)?;
let node_reward_type = conf_map.get("node_reward_type").cloned();

Ok(node_reward_type)
}

Expand Down

0 comments on commit bc83b42

Please sign in to comment.