fromTxInScript method

Address fromTxInScript(
  1. Script script
)

Implementation

Address fromTxInScript(Script script) {
  var pubKeyHashBuf = Hash.sha256Ripemd160(
    script.chunks[1].buf ?? hex.decode('00' * 32) as Uint8List,
  );
  return this.fromPubKeyHashBuf(pubKeyHashBuf.toBuffer());
}