remove old ln hack in scan parsing logic

This commit is contained in:
Omar
2026-06-05 15:30:46 +02:00
parent 0c72b08f0e
commit 1264fdbaa0
@@ -163,17 +163,18 @@ class CoinActionRow extends StatelessWidget {
late final PaymentRequest req;
var unspentCoinType = UnspentCoinType.any;
if (SendViewModelBase.isNonZeroAmountLightningInvoice(code)) {
unspentCoinType = UnspentCoinType.lightning;
final amount = CryptoCurrency.btcln.formatAmount(BigInt.from(getBolt11Amount(code) ?? 0));
req = PaymentRequest(code, amount, "", "", "");
} else if (SendViewModelBase.isLnurlInvoice(code)) {
unspentCoinType = UnspentCoinType.lightning;
final amount = CryptoCurrency.btcln.formatAmount(BigInt.from(await LNURL.getPayRequestAmount(code) ?? 0));
req = PaymentRequest(code, amount, "", "", "");
} else if (OpenCryptoPayService.isOpenCryptoPayQR(code)) {
req = PaymentRequest(code, "", "", "", "");
} else if (Uri.tryParse(code)?.scheme == "wc") {
// if (false && SendViewModelBase.isNonZeroAmountLightningInvoice(code)) {
// unspentCoinType = UnspentCoinType.lightning;
// final amount = CryptoCurrency.btcln.formatAmount(BigInt.from(getBolt11Amount(code) ?? 0));
// req = PaymentRequest(code, amount, "", "", "");
// } else if (false && SendViewModelBase.isLnurlInvoice(code)) {
// unspentCoinType = UnspentCoinType.lightning;
// final amount = CryptoCurrency.btcln.formatAmount(BigInt.from(await LNURL.getPayRequestAmount(code) ?? 0));
// req = PaymentRequest(code, amount, "", "", "");
// } else if (false &&OpenCryptoPayService.isOpenCryptoPayQR(code)) {
// req = PaymentRequest(code, "", "", "", "");
// } else
if (Uri.tryParse(code)?.scheme == "wc") {
if (!isWalletConnectCompatibleChain(walletType)) {
showPopUp<void>(
context: context,