Skip to content

Commit

Permalink
Use errors instead of fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
hyeonLewis committed Dec 16, 2024
1 parent 250b9dc commit 338a9c6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions blockchain/state/statedb.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ package state

import (
"bytes"
"errors"
"fmt"
"math/big"
"sort"
Expand Down Expand Up @@ -1182,8 +1183,8 @@ func (s *StateDB) GetTxHash() common.Hash {
}

var (
errNotExistingAddress = fmt.Errorf("there is no account corresponding to the given address")
errNotProgramAccount = fmt.Errorf("given address is not a program account")
errNotExistingAddress = errors.New("there is no account corresponding to the given address")
errNotProgramAccount = errors.New("given address is not a program account")
)

func (s *StateDB) GetContractStorageRoot(contractAddr common.Address) (common.ExtHash, error) {
Expand Down

0 comments on commit 338a9c6

Please sign in to comment.