From d33f87493ef08139d04f807a0d5170404aef1582 Mon Sep 17 00:00:00 2001 From: Oliver Gugger Date: Fri, 4 Sep 2020 16:39:52 +0200 Subject: [PATCH] routerrpc: pass in probability source --- lnrpc/routerrpc/router_server.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lnrpc/routerrpc/router_server.go b/lnrpc/routerrpc/router_server.go index c295802c..d6cd505d 100644 --- a/lnrpc/routerrpc/router_server.go +++ b/lnrpc/routerrpc/router_server.go @@ -320,11 +320,13 @@ func (s *Server) EstimateRouteFee(ctx context.Context, // that target amount, we'll only request a single route. Set a // restriction for the default CLTV limit, otherwise we can find a route // that exceeds it and is useless to us. + mc := s.cfg.RouterBackend.MissionControl route, err := s.cfg.Router.FindRoute( s.cfg.RouterBackend.SelfNode, destNode, amtMsat, &routing.RestrictParams{ - FeeLimit: feeLimit, - CltvLimit: s.cfg.RouterBackend.MaxTotalTimelock, + FeeLimit: feeLimit, + CltvLimit: s.cfg.RouterBackend.MaxTotalTimelock, + ProbabilitySource: mc.GetProbability, }, nil, nil, s.cfg.RouterBackend.DefaultFinalCltvDelta, ) if err != nil {