fix: use buy-specific address for buy/sell flow and restrict lightning invoice generation to bitcoin wallets

This commit is contained in:
Omar
2026-06-10 19:55:47 +02:00
parent 782253a653
commit dc1b369e08
2 changed files with 7 additions and 5 deletions
@@ -1071,6 +1071,7 @@ abstract class ExchangeViewModelBase extends WalletChangeListenerViewModel with
}
if (depositCurrency == CryptoCurrency.btcln &&
wallet.type == WalletType.bitcoin &&
depositAddress == wallet.walletAddresses.addressForExchange) {
final invoice = await bitcoin!.getLightningInvoice(wallet, BigInt.zero);
if (invoice != null) {
@@ -1079,6 +1080,7 @@ abstract class ExchangeViewModelBase extends WalletChangeListenerViewModel with
}
if (receiveCurrency == CryptoCurrency.btcln &&
wallet.type == WalletType.bitcoin &&
receiveAddress == wallet.walletAddresses.addressForExchange) {
final invoice = await bitcoin!.getLightningInvoice(wallet, BigInt.zero);
if (invoice != null) {