From 369a025b7cfb3ddcb157e42b3d9bed7140edc124 Mon Sep 17 00:00:00 2001 From: Prem Chaitanya Prathi Date: Mon, 8 Jan 2024 21:26:16 +0530 Subject: [PATCH] fix: use both filter and legacyFilter flags to determine if filter is enabled and set Waku2 ENR field (#996) --- waku/v2/node/wakunode2.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/waku/v2/node/wakunode2.go b/waku/v2/node/wakunode2.go index 395c6444..fdc8de67 100644 --- a/waku/v2/node/wakunode2.go +++ b/waku/v2/node/wakunode2.go @@ -200,7 +200,7 @@ func New(opts ...WakuNodeOption) (*WakuNode, error) { w.log = params.logger.Named("node2") w.wg = &sync.WaitGroup{} w.keepAliveFails = make(map[peer.ID]int) - w.wakuFlag = enr.NewWakuEnrBitfield(w.opts.enableLightPush, w.opts.enableLegacyFilter, w.opts.enableStore, w.opts.enableRelay) + w.wakuFlag = enr.NewWakuEnrBitfield(w.opts.enableLightPush, w.opts.enableFilterFullNode || w.opts.enableLegacyFilter, w.opts.enableStore, w.opts.enableRelay) w.circuitRelayNodes = make(chan peer.AddrInfo) w.metrics = newMetrics(params.prometheusReg)