routing/payment_session: remove prebuilt payment session

Since we no longer use payment sessions for send to route, we remove the
prebuilt one.
This commit is contained in:
Johan T. Halseth
2020-04-01 00:13:25 +02:00
parent 4509c4f3a9
commit 49efbefb43
4 changed files with 9 additions and 35 deletions

View File

@@ -75,23 +75,13 @@ func (m *SessionSource) NewPaymentSession(p *LightningPayment) (
}, nil
}
// NewPaymentSessionForRoute creates a new paymentSession instance that is just
// used for failure reporting to missioncontrol.
func (m *SessionSource) NewPaymentSessionForRoute(preBuiltRoute *route.Route) PaymentSession {
return &paymentSession{
sessionSource: m,
preBuiltRoute: preBuiltRoute,
}
}
// NewPaymentSessionEmpty creates a new paymentSession instance that is empty,
// and will be exhausted immediately. Used for failure reporting to
// missioncontrol for resumed payment we don't want to make more attempts for.
func (m *SessionSource) NewPaymentSessionEmpty() PaymentSession {
return &paymentSession{
sessionSource: m,
preBuiltRoute: &route.Route{},
preBuiltRouteTried: true,
sessionSource: m,
empty: true,
}
}