Skip to content

Commit

Permalink
fix(rpc/otterscan): set fullblock.tx_count with block's (paradigmxyz#…
Browse files Browse the repository at this point in the history
…10421)

Signed-off-by: jsvisa <[email protected]>
  • Loading branch information
jsvisa authored Aug 21, 2024
1 parent 1f6993d commit 5a522c8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion crates/rpc/rpc/src/otterscan.rs
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,11 @@ where
OtsTransactionReceipt { receipt, timestamp }
})
.collect();
Ok(OtsBlockTransactions { fullblock: block.inner.into(), receipts })

// use `transaction_count` to indicate the paginate information
let mut block = OtsBlockTransactions { fullblock: block.inner.into(), receipts };
block.fullblock.transaction_count = tx_len;
Ok(block)
}

/// Handler for `searchTransactionsBefore`
Expand Down

0 comments on commit 5a522c8

Please sign in to comment.