From adc71b30740c974fa97ed8300ef002de84697ee6 Mon Sep 17 00:00:00 2001 From: NagyZoltanPeter <113987313+NagyZoltanPeter@users.noreply.github.com> Date: Mon, 17 Mar 2025 10:23:55 +0100 Subject: [PATCH] Fixing lightpush publish logs stated it was legacy lightpush, also fix on wrong mounted protocol check. --- waku/node/waku_node.nim | 4 ++-- waku/waku_api/rest/lightpush/handlers.nim | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/waku/node/waku_node.nim b/waku/node/waku_node.nim index 9eeb24321..fafce4211 100644 --- a/waku/node/waku_node.nim +++ b/waku/node/waku_node.nim @@ -1146,7 +1146,7 @@ proc lightpushPublishHandler( ): Future[lightpush_protocol.WakuLightPushResult] {.async.} = let msgHash = pubsubTopic.computeMessageHash(message).to0xHex() if not node.wakuLightpushClient.isNil(): - notice "publishing message with legacy lightpush", + notice "publishing message with lightpush", pubsubTopic = pubsubTopic, contentTopic = message.contentTopic, target_peer_id = peer.peerId, @@ -1154,7 +1154,7 @@ proc lightpushPublishHandler( return await node.wakuLightpushClient.publish(some(pubsubTopic), message, peer) if not node.wakuLightPush.isNil(): - notice "publishing message with self hosted legacy lightpush", + notice "publishing message with self hosted lightpush", pubsubTopic = pubsubTopic, contentTopic = message.contentTopic, target_peer_id = peer.peerId, diff --git a/waku/waku_api/rest/lightpush/handlers.nim b/waku/waku_api/rest/lightpush/handlers.nim index cbb94e16e..601aab74c 100644 --- a/waku/waku_api/rest/lightpush/handlers.nim +++ b/waku/waku_api/rest/lightpush/handlers.nim @@ -33,7 +33,7 @@ const NoPeerNoneFoundError = RestApiResponse.serviceUnavailable("No suitable service peer & none discovered") proc useSelfHostedLightPush(node: WakuNode): bool = - return node.wakuLegacyLightPush != nil and node.wakuLegacyLightPushClient == nil + return node.wakuLightPush != nil and node.wakuLightPushClient == nil proc convertErrorKindToHttpStatus(statusCode: LightpushStatusCode): HttpCode = ## Lightpush status codes are matching HTTP status codes by design