Skip to content

Commit

Permalink
style: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
peyha committed Feb 24, 2024
1 parent 0aae02f commit 6fb34d0
Showing 1 changed file with 26 additions and 2 deletions.
28 changes: 26 additions & 2 deletions crates/freeze/src/datasets/blocks.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,31 @@ pub(crate) fn process_block<TX>(block: Block<TX>, columns: &mut Blocks, schema:
store!(schema, columns, mix_hash, block.mix_hash.map(|x| x.0.to_vec()));
store!(schema, columns, nonce, block.nonce.map(|x| x.0.to_vec()));
store!(schema, columns, withdrawals_root, block.withdrawals_root.map(|x| x.0.to_vec()));
store!(schema, columns, blob_gas_used, block.other.get_with("blobGasUsed", |x| u64::from_str_radix(x.as_str().unwrap().trim_start_matches("0x"), 16).ok()).unwrap_or(None));
store!(schema, columns, excess_blob_gas, block.other.get_with("excessBlobGas", |x| u64::from_str_radix(x.as_str().unwrap().trim_start_matches("0x"), 16).ok()).unwrap_or(None));
store!(
schema,
columns,
blob_gas_used,
block
.other
.get_with("blobGasUsed", |x| u64::from_str_radix(
x.as_str().unwrap().trim_start_matches("0x"),
16
)
.ok())
.unwrap_or(None)
);
store!(
schema,
columns,
excess_blob_gas,
block
.other
.get_with("excessBlobGas", |x| u64::from_str_radix(
x.as_str().unwrap().trim_start_matches("0x"),
16
)
.ok())
.unwrap_or(None)
);
Ok(())
}

0 comments on commit 6fb34d0

Please sign in to comment.