routerrpc: skip initiated payment in trackPaymentStream

This commit is contained in:
yyforyongyu 2023-11-14 17:46:20 +08:00
parent 5e369a02bb
commit 922130c80e
No known key found for this signature in database
GPG key ID: 9BCD95C4FF296868

View file

@ -941,10 +941,13 @@ func (s *Server) trackPaymentStream(context context.Context,
result := item.(*channeldb.MPPayment)
// Skip in-flight updates unless requested.
if noInflightUpdates &&
result.Status == channeldb.StatusInFlight {
continue
if noInflightUpdates {
if result.Status == channeldb.StatusInitiated {
continue
}
if result.Status == channeldb.StatusInFlight {
continue
}
}
rpcPayment, err := s.cfg.RouterBackend.MarshallPayment(