From 48762d6f3ca8ee929ee746a2ad0378e033e87f85 Mon Sep 17 00:00:00 2001 From: Matheus Degiovani Date: Thu, 29 Jul 2021 18:27:17 -0300 Subject: [PATCH] jsonrpc/types: Add missing Method type to vars. This adds a missing Method type declaration to the "work" and "tspend" notification method names. This allows importing both v2 and v3 versions of this package without running into RPC command registration errors. --- rpc/jsonrpc/types/chainsvrwsntfns.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rpc/jsonrpc/types/chainsvrwsntfns.go b/rpc/jsonrpc/types/chainsvrwsntfns.go index 074be7f3..1c44b65a 100644 --- a/rpc/jsonrpc/types/chainsvrwsntfns.go +++ b/rpc/jsonrpc/types/chainsvrwsntfns.go @@ -24,11 +24,11 @@ const ( // WorkNtfnMethod is the method used for notifications from // the chain server that a new block template has been generated. - WorkNtfnMethod = "work" + WorkNtfnMethod Method = "work" // TSpendNtfnMethod is the method used for notifications from the chain // server that a new tspend has arrived in the mempool. - TSpendNtfnMethod = "tspend" + TSpendNtfnMethod Method = "tspend" // ReorganizationNtfnMethod is the method used for notifications that the // block chain is in the process of a reorganization.