discovery: use errors.Is for error check

Ensure that the check works for wrapped errors. Otherwise, this breaks
for a SQLStore graph backend which wraps the error it returns.
This commit is contained in:
Elle Mouton
2025-06-25 11:28:17 +02:00
parent 3493b08785
commit e0801f5a5d

View File

@@ -236,7 +236,7 @@ func (c *ChannelGraphBootstrapper) SampleNodeAddrs(_ context.Context,
return errFound
})
if err != nil && err != errFound {
if err != nil && !errors.Is(err, errFound) {
return nil, err
}