Provide IsLikelyCoinjoin to SmartTransaction
MODIFY
WalletWasabi/Blockchain/TransactionProcessing/ProcessedResult.cs
WalletWasabi/Blockchain/TransactionProcessing/ProcessedResult.cs
@@ -14,7 +14,7 @@ public class ProcessedResult
public ProcessedResult(SmartTransaction transaction)
{
Transaction = Guard.NotNull(nameof(transaction), transaction);
- _isLikelyOwnCoinJoin = new Lazy<bool>(() => Transaction.WalletInputs.Any() && Transaction.Transaction.IsLikelyCoinjoin(), true);
+ _isLikelyOwnCoinJoin = new Lazy<bool>(() => Transaction.WalletInputs.Any() && Transaction.IsLikelyCoinjoin(), true);
}
public SmartTransaction Transaction { get; }

MODIFY
WalletWasabi/Blockchain/Transactions/TransactionHistoryBuilder.cs
WalletWasabi/Blockchain/Transactions/TransactionHistoryBuilder.cs
@@ -49,7 +49,7 @@ public class TransactionHistoryBuilder
Label = containingTransaction.Label,
TransactionId = coin.TransactionId,
BlockIndex = containingTransaction.BlockIndex,
- IsLikelyCoinJoinOutput = containingTransaction.Transaction.IsLikelyCoinjoin()
+ IsLikelyCoinJoinOutput = containingTransaction.IsLikelyCoinjoin()
});
}
@@ -74,7 +74,7 @@ public class TransactionHistoryBuilder
Label = spenderTransaction.Label,
TransactionId = spenderTxId,
BlockIndex = spenderTransaction.BlockIndex,
- IsLikelyCoinJoinOutput = spenderTransaction.Transaction.IsLikelyCoinjoin()
+ IsLikelyCoinJoinOutput = spenderTransaction.IsLikelyCoinjoin()
});
}
}

MODIFY
WalletWasabi/Extensions/NBitcoinExtensions.cs
WalletWasabi/Extensions/NBitcoinExtensions.cs
@@ -150,9 +150,9 @@ public static class NBitcoinExtensions
return anonsets;
}
- public static bool IsLikelyCoinjoin(this Transaction me)
- => me.Inputs.Count > 1 // The tx must have more than one input in order to be a coinjoin.
- && me.HasIndistinguishableOutputs(); // The tx must have more than one equal output in order to be a coinjoin.
+ public static bool IsLikelyCoinjoin(this SmartTransaction me)
+ => me.Transaction.Inputs.Count > 1 // The tx must have more than one input in order to be a coinjoin.
+ && me.Transaction.HasIndistinguishableOutputs(); // The tx must have more than one equal output in order to be a coinjoin.
/// <summary>
/// Careful, if it's in a legacy block then this won't work.

Provide IsLikelyCoinjoin to SmartTransaction