diff --git a/apps/chat2/chat2.nim b/apps/chat2/chat2.nim index 98081754e..dd01e81e8 100644 --- a/apps/chat2/chat2.nim +++ b/apps/chat2/chat2.nim @@ -515,7 +515,7 @@ proc processInput(rfd: AsyncFD, rng: ref HmacDrbgContext) {.async.} = rlnRelayCredentialsPassword: conf.rlnRelayCredentialsPassword ) - await node.mountRlnRelay(rlnConf, + waitFor node.mountRlnRelay(rlnConf, spamHandler=some(spamHandler)) let membershipIndex = node.wakuRlnRelay.groupManager.membershipIndex.get() diff --git a/apps/wakunode2/app.nim b/apps/wakunode2/app.nim index 60fd5f394..91863cc35 100644 --- a/apps/wakunode2/app.nim +++ b/apps/wakunode2/app.nim @@ -408,7 +408,7 @@ proc setupProtocols(node: WakuNode, ) try: - await node.mountRlnRelay(rlnConf) + waitFor node.mountRlnRelay(rlnConf) except CatchableError: return err("failed to mount waku RLN relay protocol: " & getCurrentExceptionMsg()) diff --git a/waku/node/waku_node.nim b/waku/node/waku_node.nim index 170a2dcf2..ade92de41 100644 --- a/waku/node/waku_node.nim +++ b/waku/node/waku_node.nim @@ -731,11 +731,8 @@ when defined(rln): if node.wakuRelay.isNil(): raise newException(CatchableError, "WakuRelay protocol is not mounted, cannot mount WakuRlnRelay") - # TODO: check whether the pubsub topic is supported at the relay level - # if rlnConf.rlnRelayPubsubTopic notin node.wakuRelay.defaultPubsubTopics: - # error "The relay protocol does not support the configured pubsub topic for WakuRlnRelay" - let rlnRelayRes = await WakuRlnRelay.new(rlnConf, + let rlnRelayRes = waitFor WakuRlnRelay.new(rlnConf, registrationHandler) if rlnRelayRes.isErr(): raise newException(CatchableError, "failed to mount WakuRlnRelay: " & rlnRelayRes.error)