clean up + removed smaller suggestion for now
MODIFY
WalletWasabi.Fluent/ViewModels/Wallets/Send/ChangeAvoidanceSuggestionViewModel.cs
WalletWasabi.Fluent/ViewModels/Wallets/Send/ChangeAvoidanceSuggestionViewModel.cs
@@ -49,32 +49,6 @@ public partial class ChangeAvoidanceSuggestionViewModel : SuggestionViewModel
public static async IAsyncEnumerable<ChangeAvoidanceSuggestionViewModel> GenerateSuggestionsAsync(
TransactionInfo transactionInfo, BitcoinAddress destination, Wallet wallet, BuildTransactionResult requestedTransaction, [EnumeratorCancellation] CancellationToken cancellationToken)
{
- ChangeAvoidanceSuggestionViewModel? smallerSuggestion = null;
-
- if (requestedTransaction.SpentCoins.Count() > 1)
- {
- var smallerTransaction = await Task.Run(() => TransactionHelpers.BuildChangelessTransaction(
- wallet,
- destination,
- transactionInfo.UserLabels,
- transactionInfo.FeeRate,
- requestedTransaction
- .SpentCoins
- .OrderByDescending(x => x.Amount)
- .Skip(1),
- tryToSign: false
- ));
-
- var smallerDestinationAmount = smallerTransaction.CalculateDestinationAmount();
-
- if (smallerDestinationAmount < transactionInfo.Amount)
- {
- smallerSuggestion = new ChangeAvoidanceSuggestionViewModel(
- transactionInfo.Amount.ToDecimal(MoneyUnit.BTC), smallerTransaction,
- wallet.Synchronizer.UsdExchangeRate, false);
- }
- }
-
Task<ChangeAvoidanceSuggestionViewModel?> bnbSuggestionTask = Task.Run(() =>
{
List<SmartCoin> availableCoins = wallet.Coins.Available().ToList();
@@ -99,11 +73,6 @@ public partial class ChangeAvoidanceSuggestionViewModel : SuggestionViewModel
return null;
});
- if (smallerSuggestion is not null)
- {
- yield return smallerSuggestion;
- }
-
ChangeAvoidanceSuggestionViewModel? bnbSuggestion = await bnbSuggestionTask;
if (bnbSuggestion is not null)

MODIFY
WalletWasabi.Fluent/ViewModels/Wallets/Send/LoadingSuggestionViewModel.cs
WalletWasabi.Fluent/ViewModels/Wallets/Send/LoadingSuggestionViewModel.cs
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
namespace WalletWasabi.Fluent.ViewModels.Wallets.Send;
public class LoadingSuggestionViewModel : SuggestionViewModel

clean up + removed smaller suggestion for now