staticaddr: remove duplicate deposit finalize method

This commit is contained in:
Slyghtning 2025-06-13 13:29:54 +02:00
parent f7769d2bf8
commit 3963bad3a1
No known key found for this signature in database
GPG key ID: F82D456EA023C9BF
2 changed files with 1 additions and 16 deletions

View file

@ -137,21 +137,6 @@ func (f *FSM) WaitForExpirySweepAction(ctx context.Context,
}
}
// SweptExpiredDepositAction is the final action of the FSM. It signals to the
// manager that the deposit has been swept and the FSM can be removed. It also
// ends the state machine main loop by cancelling its context.
func (f *FSM) SweptExpiredDepositAction(ctx context.Context,
_ fsm.EventContext) fsm.EventType {
select {
case <-ctx.Done():
return fsm.OnError
case f.finalizedDepositChan <- f.deposit.OutPoint:
return fsm.NoOp
}
}
// FinalizeDepositAction is the final action after a withdrawal. It signals to
// the manager that the deposit has been swept and the FSM can be removed.
func (f *FSM) FinalizeDepositAction(ctx context.Context,

View file

@ -292,7 +292,7 @@ func (f *FSM) DepositStatesV0() fsm.States {
Transitions: fsm.Transitions{
OnExpiry: Expired,
},
Action: f.SweptExpiredDepositAction,
Action: f.FinalizeDepositAction,
},
Withdrawing: fsm.State{
Transitions: fsm.Transitions{