diff --git a/waku/v2/protocol/enr/shards.go b/waku/v2/protocol/enr/shards.go index 29adc2d5..de1e7a57 100644 --- a/waku/v2/protocol/enr/shards.go +++ b/waku/v2/protocol/enr/shards.go @@ -1,10 +1,9 @@ package enr import ( - "errors" - "github.com/ethereum/go-ethereum/p2p/enode" "github.com/ethereum/go-ethereum/p2p/enr" + "github.com/waku-org/go-waku/waku/v2/protocol" ) @@ -43,21 +42,6 @@ func WithWakuRelaySharding(rs protocol.RelayShards) ENROption { } } -func WithWakuRelayShardingTopics(topics ...string) ENROption { - return func(localnode *enode.LocalNode) error { - rs, err := protocol.TopicsToRelayShards(topics...) - if err != nil { - return err - } - - if len(rs) != 1 { - return errors.New("expected a single RelayShards") - } - - return WithWakuRelaySharding(rs[0])(localnode) - } -} - // ENR record accessors func RelayShardList(record *enr.Record) (*protocol.RelayShards, error) {