Skip to content

Commit

Permalink
Resolve merge for testnet3
Browse files Browse the repository at this point in the history
  • Loading branch information
howardwu committed Mar 23, 2024
1 parent f3779c9 commit 94d1135
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 9 deletions.
6 changes: 0 additions & 6 deletions ledger/block/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,12 +125,6 @@ impl<N: Network> Block<N> {
transactions: Transactions<N>,
aborted_transaction_ids: Vec<N::TransactionID>,
) -> Result<Self> {
// Ensure the block contains transactions.
ensure!(
!transactions.is_empty() || !aborted_transaction_ids.is_empty(),
"Cannot create a block with zero transactions"
);

// Ensure the number of transactions is within the allowed range.
if transactions.len() > Transactions::<N>::MAX_TRANSACTIONS {
bail!(
Expand Down
3 changes: 0 additions & 3 deletions ledger/block/src/verify.rs
Original file line number Diff line number Diff line change
Expand Up @@ -389,9 +389,6 @@ impl<N: Network> Block<N> {
fn verify_transactions(&self) -> Result<()> {
let height = self.height();

// Ensure there are transactions.
ensure!(!self.transactions.is_empty(), "Block {height} must contain at least 1 transaction");

// Ensure the number of transactions is within the allowed range.
if self.transactions.len() > Transactions::<N>::MAX_TRANSACTIONS {
bail!(
Expand Down

0 comments on commit 94d1135

Please sign in to comment.