Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
shaorongqiang committed Sep 20, 2023
1 parent 285eb73 commit 031a145
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/components/contracts/rpc/src/eth_pubsub.rs
Original file line number Diff line number Diff line change
Expand Up @@ -219,9 +219,9 @@ impl SubscriptionResult {
receipts: Vec<Receipt>,
params: &FilteredParams,
) -> Vec<Log> {
let block_hash = Some(H256::from_slice(
let block_hash = H256::from_slice(
Keccak256::digest(&rlp::encode(&block.header)).as_slice(),
));
);
let mut logs: Vec<Log> = vec![];
let mut log_index: u32 = 0;
for (receipt_index, receipt) in receipts.into_iter().enumerate() {
Expand All @@ -239,7 +239,7 @@ impl SubscriptionResult {
address: log.address,
topics: log.topics,
data: Bytes(log.data),
block_hash,
Some(block_hash),
block_number: Some(block.header.number),
transaction_hash,
transaction_index: Some(U256::from(receipt_index)),
Expand Down
2 changes: 1 addition & 1 deletion src/components/finutils/src/bins/cfg_generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ fn gen() -> Result<()> {
cfg_template
.valiators
.iter_mut()
.zip(id_list.into_iter())
.zip(id_list)
.for_each(|(v, id)| {
v.id = id;
});
Expand Down
2 changes: 1 addition & 1 deletion src/ledger/src/store/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1026,7 +1026,7 @@ impl LedgerState {

let res = sids
.into_iter()
.zip(aus.into_iter())
.zip(aus)
.filter_map(|(sid, au)| au.map(|au| (sid, au)))
.map(|(sid, au)| {
(
Expand Down

0 comments on commit 031a145

Please sign in to comment.