mirror of
https://github.com/aljazceru/breez-lnd.git
synced 2026-01-07 08:24:20 +01:00
rpcserver+routerrpc: remove payment limit
This commit is contained in:
@@ -27,9 +27,6 @@ import (
|
||||
// RouterBackend contains the backend implementation of the router rpc sub
|
||||
// server calls.
|
||||
type RouterBackend struct {
|
||||
// MaxPaymentMSat is the largest payment permitted by the backend.
|
||||
MaxPaymentMSat lnwire.MilliSatoshi
|
||||
|
||||
// SelfNode is the vertex of the node sending the payment.
|
||||
SelfNode route.Vertex
|
||||
|
||||
@@ -143,10 +140,6 @@ func (r *RouterBackend) QueryRoutes(ctx context.Context,
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if amt > r.MaxPaymentMSat {
|
||||
return nil, fmt.Errorf("payment of %v is too large, max payment "+
|
||||
"allowed is %v", amt, r.MaxPaymentMSat.ToSatoshis())
|
||||
}
|
||||
|
||||
// Unmarshall restrictions from request.
|
||||
feeLimit := lnrpc.CalculateFeeLimit(in.FeeLimit, amt)
|
||||
@@ -489,13 +482,6 @@ func (r *RouterBackend) UnmarshallRoute(rpcroute *lnrpc.Route) (
|
||||
return nil, err
|
||||
}
|
||||
|
||||
if routeHop.AmtToForward > r.MaxPaymentMSat {
|
||||
return nil, fmt.Errorf("payment of %v is too large, "+
|
||||
"max payment allowed is %v",
|
||||
routeHop.AmtToForward,
|
||||
r.MaxPaymentMSat.ToSatoshis())
|
||||
}
|
||||
|
||||
hops[i] = routeHop
|
||||
|
||||
prevNodePubKey = routeHop.PubKeyBytes
|
||||
|
||||
Reference in New Issue
Block a user