validator/pow: store block difficulty info in sled

This commit is contained in:
aggstam
2023-10-13 19:40:18 +03:00
parent 594946044e
commit 893ea4a52f
9 changed files with 252 additions and 25 deletions

View File

@@ -40,7 +40,7 @@ struct Node {
impl Node {
fn new() -> Result<Self> {
let blockchain = Blockchain::new(&sled::Config::new().temporary(true).open()?)?;
let module = PoWModule::new(blockchain.clone(), None, POW_TARGET);
let module = PoWModule::new(blockchain.clone(), None, POW_TARGET)?;
Ok(Self { blockchain, module })
}
}