]> Untitled Git - bdk/commitdiff
Merge bitcoindevkit/bdk#1841: Generalize `add_recipient` to accept `Address`
authorvalued mammal <valuedmammal@protonmail.com>
Mon, 10 Mar 2025 16:37:51 +0000 (12:37 -0400)
committervalued mammal <valuedmammal@protonmail.com>
Mon, 10 Mar 2025 16:37:51 +0000 (12:37 -0400)
de2c44fc183b3b43816cfe6c868c8cea7d749d7b feat(wallet): generalize `add_recipient` to accept `Address` (Rob N)

Pull request description:

  ### Description

  I would imagine many users would be handling a `Address<NetworkChecked>` when building a transaction. They may pass this structure directly with this patch, or continue to use `ScriptBuf`.

  ### Notes to the reviewers

  To my knowledge this is non-breaking, but it is a change in the function signature so I am not sure.

  ### Changelog notice

  Accept any type that is convertible to a `ScriptBuf` in `TxBuilder::add_recipient`

  ### Checklists

  #### All Submissions:

  * [x] I've signed all my commits
  * [x] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)
  * [x] I ran `cargo fmt` and `cargo clippy` before committing

  #### New Features:

  * [ ] I've added tests for the new feature
  * [ ] I've added docs for the new feature

  #### Bugfixes:

  * [ ] This pull request breaks the existing API
  * [ ] I've added tests to reproduce the issue which are now passing
  * [ ] I'm linking the issue being fixed by this PR

ACKs for top commit:
  ValuedMammal:
    reACK de2c44fc183b3b43816cfe6c868c8cea7d749d7b

Tree-SHA512: 42a266190964e8afa1ade8f5a054b9ce86dc61728c8c441c7dad5c5b70459543617515b28199467e7dab3721bef24cffde2b9c807a6f7f0ec4f814caebafd93d


Trivial merge