Skip to content

Commit

Permalink
fix: default dev account printing
Browse files Browse the repository at this point in the history
  • Loading branch information
jakim929 committed Sep 24, 2024
1 parent ac09226 commit 78aebf0
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions config/chain.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ import (

"github.com/ethereum/go-ethereum/accounts"
"github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/common/hexutil"
"github.com/ethereum/go-ethereum/core/types"
"github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/ethclient"
)

Expand Down Expand Up @@ -159,8 +161,8 @@ func DefaultSecretsConfigAsString() string {
fmt.Fprintf(&b, "-----------------------\n")

for i := range DefaultSecretsConfig.Accounts {
privateKeyHex, _ := keys.Secret(devkeys.UserKey(i))
fmt.Fprintf(&b, "(%d): %s\n", i, privateKeyHex)
privateKey, _ := keys.Secret(devkeys.UserKey(i))
fmt.Fprintf(&b, "(%d): %s\n", i, hexutil.Encode(crypto.FromECDSA(privateKey)))
}

return b.String()
Expand Down

0 comments on commit 78aebf0

Please sign in to comment.