We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6269a1b commit 1e3f09fCopy full SHA for 1e3f09f
src/transaction.rs
@@ -596,8 +596,16 @@ impl Transaction {
596
self.lock_time.consensus_encode(&mut enc).unwrap();
597
bitcoin::Txid::from_engine(enc)
598
}
599
+
600
+ /// Get the witness txid of the transaction.
601
+ pub fn wtxid(&self) -> bitcoin::Wtxid {
602
+ let mut enc = Txid::engine();
603
+ self.consensus_encode(&mut enc).unwrap();
604
+ bitcoin::Wtxid::from_engine(enc)
605
+ }
606
607
608
+//TODO(stevenroose) remove this, it's incorrect
609
impl BitcoinHash<Txid> for Transaction {
610
/// To get a transaction's txid, which is usually what you want, use the `txid` method.
611
fn bitcoin_hash(&self) -> Txid {
0 commit comments