Skip to content

Commit

Permalink
PR feedback + fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
djb15 committed Feb 21, 2025
1 parent 7fb97d0 commit 7e41e04
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
5 changes: 2 additions & 3 deletions node/cmd/guardiand/adminclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -349,9 +349,8 @@ func runDumpVAAByMessageID(cmd *cobra.Command, args []string) {
if err != nil {
log.Fatalf("invalid chain ID: %v", err)
}
// We only constrain this to int32 now, not uint16, given the ChainID protobuf definition
if chainID > math.MaxInt32 {
log.Fatalf("chain id must not exceed the max int32: %v", chainID)
if chainID > math.MaxUint16 {
log.Fatalf("chain id must not exceed the max uint16: %v", chainID)
}
emitterAddress := parts[1]
seq, err := strconv.ParseUint(parts[2], 10, 64)
Expand Down
2 changes: 1 addition & 1 deletion node/pkg/watchers/near/watcher_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@ func TestSuccessValueToInt(t *testing.T) {

type test struct {
input string
output int
output uint64
}

testsPositive := []test{
Expand Down

0 comments on commit 7e41e04

Please sign in to comment.