diff --git a/bitcoin/src/address.rs b/bitcoin/src/address.rs index 5c04b20c..4cfffbb8 100644 --- a/bitcoin/src/address.rs +++ b/bitcoin/src/address.rs @@ -1014,6 +1014,12 @@ impl Address { } } +impl From
for script::ScriptBuf { + fn from(a: Address) -> Self { + a.script_pubkey() + } +} + // Alternate formatting `{:#}` is used to return uppercase version of bech32 addresses which should // be used in QR codes, see [`Address::to_qr_uri`]. impl fmt::Display for Address {