Skip to content

Commit

Permalink
chore: rename variable
Browse files Browse the repository at this point in the history
  • Loading branch information
izyak committed Jul 25, 2023
1 parent 0b6e184 commit 755af4f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions relayer/chains/archway/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ type ArchwayProviderConfig struct {
IbcHandlerAddress string `json:"ibc-handler-address" yaml:"ibc-handler-address"`
FirstRetryBlockAfter uint64 `json:"first-retry-block-after" yaml:"first-retry-block-after"`
StartHeight uint64 `json:"start-height" yaml:"start-height"`
ChainBlockInterval uint64 `json:"block-interval" yaml:"block-interval"`
BlockInterval uint64 `json:"block-interval" yaml:"block-interval"`
}

type ArchwayIBCHeader struct {
Expand Down Expand Up @@ -194,7 +194,7 @@ func (pp *ArchwayProviderConfig) Validate() error {
return fmt.Errorf("Ibc handler contract cannot be empty")
}

if pp.ChainBlockInterval == 0 {
if pp.BlockInterval == 0 {
return fmt.Errorf("Block interval cannot be zero")
}

Expand All @@ -210,7 +210,7 @@ func (pp *ArchwayProviderConfig) BroadcastMode() provider.BroadcastMode {
}

func (pp *ArchwayProviderConfig) GetBlockInterval() uint64 {
return pp.ChainBlockInterval
return pp.BlockInterval
}

func (pp *ArchwayProviderConfig) GetFirstRetryBlockAfter() uint64 {
Expand Down
6 changes: 3 additions & 3 deletions relayer/chains/icon/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ type IconProviderConfig struct {
IbcHandlerAddress string `json:"ibc-handler-address" yaml:"ibc-handler-address"`
FirstRetryBlockAfter uint64 `json:"first-retry-block-after" yaml:"first-retry-block-after"`
StartHeight uint64 `json:"start-height" yaml:"start-height"`
ChainBlockInterval uint64 `json:"block-interval" yaml:"block-interval"`
BlockInterval uint64 `json:"block-interval" yaml:"block-interval"`
}

func (pp *IconProviderConfig) Validate() error {
Expand All @@ -74,15 +74,15 @@ func (pp *IconProviderConfig) Validate() error {
return fmt.Errorf("Ibc handler Address cannot be empty")
}

if pp.ChainBlockInterval == 0 {
if pp.BlockInterval == 0 {
return fmt.Errorf("Block interval cannot be zero")
}

return nil
}

func (pp *IconProviderConfig) GetBlockInterval() uint64 {
return pp.ChainBlockInterval
return pp.BlockInterval
}

func (pp *IconProviderConfig) GetFirstRetryBlockAfter() uint64 {
Expand Down

0 comments on commit 755af4f

Please sign in to comment.