routing: use [33]byte instead of *btcutil.Publickey for SendToSwitch
With this change, we can avoid unnecessarily serializing a public key.
This commit is contained in:
parent
22951cb364
commit
1f3124f48a
@ -130,7 +130,7 @@ type Config struct {
|
|||||||
// forward a fully encoded payment to the first hop in the route
|
// forward a fully encoded payment to the first hop in the route
|
||||||
// denoted by its public key. A non-nil error is to be returned if the
|
// denoted by its public key. A non-nil error is to be returned if the
|
||||||
// payment was unsuccessful.
|
// payment was unsuccessful.
|
||||||
SendToSwitch func(firstHop *btcec.PublicKey, htlcAdd *lnwire.UpdateAddHTLC,
|
SendToSwitch func(firstHop [33]byte, htlcAdd *lnwire.UpdateAddHTLC,
|
||||||
circuit *sphinx.Circuit) ([sha256.Size]byte, error)
|
circuit *sphinx.Circuit) ([sha256.Size]byte, error)
|
||||||
|
|
||||||
// ChannelPruneExpiry is the duration used to determine if a channel
|
// ChannelPruneExpiry is the duration used to determine if a channel
|
||||||
|
Loading…
Reference in New Issue
Block a user