decred / dcrwallet

A secure Decred wallet daemon written in Go (golang).
https://decred.org
ISC License
212 stars 153 forks source link

spv: Request cfilters only for best chain #2302

Closed matheusd closed 7 months ago

matheusd commented 7 months ago

This changes the initial cfilter fetch to request cfilters only for the best sidechain. This avoids having to perform work for sidechains that are not (and will never) become the main chain.

Additionally, this refactors the initial cfilter fetching logic to a separate function. In the future, this will help in refactoring the cfilter fetching to perform it in a batched fashion.