Move getNewAddress(account) to HDWalletApi (#4540)

This commit is contained in:
Chris Stewart 2022-07-25 10:48:02 -05:00 committed by GitHub
parent a2e7c428cf
commit 44e09270d9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 0 deletions

View File

@ -44,6 +44,8 @@ trait HDWalletApi extends WalletApi {
def getUnconfirmedBalance(account: HDAccount): Future[CurrencyUnit]
def getNewAddress(account: HDAccount): Future[BitcoinAddress]
/** Generates a new change address */
def getNewChangeAddress(account: AccountDb): Future[BitcoinAddress]

View File

@ -229,6 +229,10 @@ class WalletHolder(implicit ec: ExecutionContext)
override def getNewAddress(addressType: AddressType): Future[BitcoinAddress] =
delegate(_.getNewAddress(addressType))
override def getNewAddress(account: HDAccount): Future[BitcoinAddress] = {
delegate(_.getNewAddress(account))
}
override def getNewAddress(): Future[BitcoinAddress] = delegate(
_.getNewAddress())