Skip to content

Commit 458978b

Browse files
committed
f Check block height didn't change
1 parent a35ed90 commit 458978b

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

src/access.rs

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -137,13 +137,15 @@ where
137137
if let Some(block_height) = tx_status.block_height {
138138
let block_header = client.get_header(block_height).await?;
139139
if let Some(merkle_proof) = client.get_merkle_proof(&txid).await? {
140-
confirmed_txs.push((
141-
tx,
142-
block_height,
143-
block_header,
144-
merkle_proof.pos,
145-
));
146-
continue;
140+
if block_height == merkle_proof.block_height {
141+
confirmed_txs.push((
142+
tx,
143+
block_height,
144+
block_header,
145+
merkle_proof.pos,
146+
));
147+
continue;
148+
}
147149
}
148150
}
149151
}

0 commit comments

Comments
 (0)