Fix nullability complain
MODIFY
WalletWasabi.Tests/UnitTests/WabiSabi/Backend/SignTransactionTests.cs
WalletWasabi.Tests/UnitTests/WabiSabi/Backend/SignTransactionTests.cs
@@ -26,9 +26,8 @@ namespace WalletWasabi.Tests.UnitTests.WabiSabi.Backend
using Key key = new();
Alice alice = WabiSabiFactory.CreateAlice(key: key);
round.Alices.Add(alice);
- var coinjoin = Transaction.Create(Network.Main);
+ var coinjoin = round.Coinjoin;
coinjoin.Inputs.Add(alice.Coins.First().Outpoint);
- round.Coinjoin = coinjoin;
round.Phase = Phase.TransactionSigning;
arena.OnTryGetRound = _ => round;
@@ -86,10 +85,9 @@ namespace WalletWasabi.Tests.UnitTests.WabiSabi.Backend
Alice alice2 = WabiSabiFactory.CreateAlice(key: key2);
round.Alices.Add(alice1);
round.Alices.Add(alice2);
- var coinjoin = Transaction.Create(Network.Main);
+ var coinjoin = round.Coinjoin;
coinjoin.Inputs.Add(alice1.Coins.First().Outpoint);
coinjoin.Inputs.Add(alice2.Coins.First().Outpoint);
- round.Coinjoin = coinjoin;
round.Phase = Phase.TransactionSigning;
arena.OnTryGetRound = _ => round;

MODIFY
WalletWasabi/WabiSabi/Backend/Rounds/Round.cs
WalletWasabi/WabiSabi/Backend/Rounds/Round.cs
@@ -49,6 +49,8 @@ namespace WalletWasabi.WabiSabi.Backend.Rounds
AmountCredentialIssuerParameters = AmountCredentialIssuer.CredentialIssuerSecretKey.ComputeCredentialIssuerParameters();
WeightCredentialIssuerParameters = WeightCredentialIssuer.CredentialIssuerSecretKey.ComputeCredentialIssuerParameters();
+ Coinjoin = Transaction.Create(Network);
+
Hash = new(HashHelpers.GenerateSha256Hash($"{Id}{MaxInputCountByAlice}{MinRegistrableAmount}{MaxRegistrableAmount}{RegistrableWeightCredentials}{AmountCredentialIssuerParameters}{WeightCredentialIssuerParameters}{FeeRate.SatoshiPerByte}"));
}
@@ -97,7 +99,7 @@ namespace WalletWasabi.WabiSabi.Backend.Rounds
public ISet<OutPoint> BlameWhitelist { get; } = new HashSet<OutPoint>();
private object Lock { get; } = new();
public byte[] UnsignedTxSecret { get; }
- public Transaction Coinjoin { get; set; }
+ public Transaction Coinjoin { get; }
public InputsRegistrationResponse RegisterAlice(
Alice alice,

Fix nullability complain