Skip to content

Commit

Permalink
fix: fix slice init length
Browse files Browse the repository at this point in the history
  • Loading branch information
wangjingcun authored Oct 24, 2024
1 parent c1ce6d7 commit 67572e5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vochain/state/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ func CheckDuplicateDelegates(delegates [][]byte, addr *ethcommon.Address) error
}

func printPrettierDelegates(delegates [][]byte) []string {
prettierDelegates := make([]string, len(delegates))
prettierDelegates := make([]string, 0, len(delegates))
for _, delegate := range delegates {
prettierDelegates = append(prettierDelegates, ethcommon.BytesToAddress(delegate).String())
}
Expand Down

0 comments on commit 67572e5

Please sign in to comment.