From 3544d65ecd35a5edc489bcfb73a3a3de07dd6b76 Mon Sep 17 00:00:00 2001 From: Anna Shaleva Date: Fri, 20 Oct 2023 17:28:57 +0300 Subject: [PATCH] rpcclient: disable linter for documentation example Disable the following linter warning: ``` superfluous-else: if block ends with call to panic function, so drop this else and outdent its block (revive) ``` Signed-off-by: Anna Shaleva --- pkg/rpcclient/invoker/doc_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/rpcclient/invoker/doc_test.go b/pkg/rpcclient/invoker/doc_test.go index 882f35a65..37a718b35 100644 --- a/pkg/rpcclient/invoker/doc_test.go +++ b/pkg/rpcclient/invoker/doc_test.go @@ -34,7 +34,7 @@ func ExampleInvoker() { res, _ := inv.Call(neo.Hash, "transfer", acc, util.Uint160{1, 2, 3}, 1, nil) if res.State == vmstate.Halt.String() { panic("NEO is broken!") // inv has no signers and transfer requires a witness to be performed. - } else { + } else { // nolint:superfluous-else // superfluous-else: if block ends with call to panic function, so drop this else and outdent its block (revive) println("ok") // this actually should fail }