Fix Payjoin test randomly crashing

This commit is contained in:
nicolas.dorier
2021-03-23 18:34:34 +09:00
parent af9d896510
commit 485faf0141

View File

@@ -285,6 +285,7 @@ namespace BTCPayServer.Payments.PayJoin
if (!await _payJoinRepository.TryLockInputs(ctx.OriginalTransaction.Inputs.Select(i => i.PrevOut).ToArray()))
{
ctx.DoNotBroadcast();
return CreatePayjoinErrorAndLog(503, PayjoinReceiverWellknownErrors.Unavailable, "Some of those inputs have already been used to make another payjoin transaction");
}