Skip to content

Commit

Permalink
refactor and cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
saibatizoku committed Nov 23, 2021
1 parent 41ed7d3 commit 58d32c1
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions chain-impl-mockchain/src/config.rs
Expand Up @@ -848,6 +848,13 @@ impl ConfigParamVariant for EvmConfigParams {
}

fn from_payload(payload: &[u8]) -> Result<Self, Error> {
fn check_bool(b: u8) -> Result<bool, Error> {
match b {
0 => Ok(false),
1 => Ok(true),
_ => Err(Error::BoolInvalid),
}
}
let mut rb = ReadBuf::from(payload);

// Read EvmConfig and match hard fork variant
Expand Down

0 comments on commit 58d32c1

Please sign in to comment.