From 4237ed34c685532fb529b0928dc9f6c77c958deb Mon Sep 17 00:00:00 2001 From: Lucas Menendez Date: Wed, 25 Sep 2024 16:01:07 +0200 Subject: [PATCH] unreachable return after panic --- api/transaction.go | 2 -- 1 file changed, 2 deletions(-) diff --git a/api/transaction.go b/api/transaction.go index 9781634..669f044 100644 --- a/api/transaction.go +++ b/api/transaction.go @@ -91,7 +91,6 @@ func (a *API) signTxHandler(w http.ResponseWriter, r *http.Request) { amount, ok := a.account.TxCosts[models.TxType_CREATE_ACCOUNT] if !ok { panic("invalid tx type") - return } // generate the faucet package with the calculated amount faucetPkg, err := a.account.FaucetPackage(organizationSigner.AddressString(), amount) @@ -124,7 +123,6 @@ func (a *API) signTxHandler(w http.ResponseWriter, r *http.Request) { amount, ok := a.account.TxCosts[models.TxType_NEW_PROCESS] if !ok { panic("invalid tx type") - return } // increment the amount with the election price to fund the // faucet package with the required amount for this type of