refundNonInflightBatchTransactions refunds all non-inflight transactions in a batch
(ctx context.Context, batchID string)
| 2431 | |
| 2432 | // refundNonInflightBatchTransactions refunds all non-inflight transactions in a batch |
| 2433 | func (l *LedgerForge) refundNonInflightBatchTransactions(ctx context.Context, batchID string) (string, error) { |
| 2434 | _, err := l.ProcessTransactionInBatches( |
| 2435 | ctx, |
| 2436 | batchID, |
| 2437 | big.NewInt(0), |
| 2438 | 1, // Assuming 1 worker is sufficient for rollback, adjust if needed |
| 2439 | false, |
| 2440 | l.GetRefundableTransactionsByParentID, |
| 2441 | l.RefundWorker, |
| 2442 | ) |
| 2443 | return "refunded", err |
| 2444 | } |
| 2445 | |
| 2446 | // logRollbackResult logs the outcome of a rollback operation |
| 2447 | func (l *LedgerForge) logRollbackResult(batchID string, action string, err error) { |
no test coverage detected