Commit 15a18b8
committed
Avoid adding duplicate hint candidates if they are first hops
If we have a direct channel to a node generating an invoice with route
hints, we'd previously happily add multiple candidates that all refer to
the same channel. To keep our candidate set small and unify our tracking
where possible, we now check if its `short_channel_id` is an
`outbound_scid_alias` of any of our first hops and refrain from adding
another candidate if it's the case.1 parent efd66db commit 15a18b8
1 file changed
Lines changed: 11 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2126 | 2126 | | |
2127 | 2127 | | |
2128 | 2128 | | |
| 2129 | + | |
| 2130 | + | |
| 2131 | + | |
| 2132 | + | |
| 2133 | + | |
| 2134 | + | |
| 2135 | + | |
| 2136 | + | |
| 2137 | + | |
2129 | 2138 | | |
2130 | 2139 | | |
2131 | 2140 | | |
| |||
2169 | 2178 | | |
2170 | 2179 | | |
2171 | 2180 | | |
2172 | | - | |
| 2181 | + | |
2173 | 2182 | | |
2174 | 2183 | | |
2175 | 2184 | | |
2176 | 2185 | | |
2177 | | - | |
| 2186 | + | |
2178 | 2187 | | |
2179 | 2188 | | |
2180 | 2189 | | |
| |||
0 commit comments