Skip to content

Commit

Permalink
Merge branch 'develop' into fix-trailofbits-block-height-check
Browse files Browse the repository at this point in the history
  • Loading branch information
ws4charlie authored Jan 26, 2024
2 parents f70a0dd + 62e1bfd commit b1598c7
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 17 deletions.
4 changes: 4 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@
* [1591](https://github.com/zeta-chain/node/pull/1591) - support lower gas limit for voting on inbound and outbound transactions
* [1592](https://github.com/zeta-chain/node/issues/1592) - check inbound tracker tx hash against Tss address and some refactor on inTx observation

### Refactoring

* [1628](https://github.com/zeta-chain/node/pull/1628) optimize return and simplify code

## Version: v12.0.0

### Breaking Changes
Expand Down
5 changes: 1 addition & 4 deletions common/chain.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,7 @@ type Chains []Chain

// IsEqual compare two chain to see whether they represent the same chain
func (chain Chain) IsEqual(c Chain) bool {
if chain.ChainId == c.ChainId {
return true
}
return false
return chain.ChainId == c.ChainId
}

func (chain Chain) IsZetaChain() bool {
Expand Down
6 changes: 1 addition & 5 deletions rpc/namespaces/ethereum/debug/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,7 @@ import (
func isCPUProfileConfigurationActivated(ctx *server.Context) bool {
// TODO: use same constants as server/start.go
// constant declared in start.go cannot be imported (cyclical dependency)
const flagCPUProfile = "cpu-profile"
if cpuProfile := ctx.Viper.GetString(flagCPUProfile); cpuProfile != "" {
return true
}
return false
return ctx.Viper.GetString("cpu-profile") != ""
}

// ExpandHome expands home directory in file paths.
Expand Down
5 changes: 1 addition & 4 deletions x/crosschain/keeper/cctx_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,5 @@ func (k Keeper) GetRevertGasLimit(ctx sdk.Context, cctx types.CrossChainTx) (uin

func IsPending(cctx types.CrossChainTx) bool {
// pending inbound is not considered a "pending" state because it has not reached consensus yet
if cctx.CctxStatus.Status == types.CctxStatus_PendingOutbound || cctx.CctxStatus.Status == types.CctxStatus_PendingRevert {
return true
}
return false
return cctx.CctxStatus.Status == types.CctxStatus_PendingOutbound || cctx.CctxStatus.Status == types.CctxStatus_PendingRevert
}
5 changes: 1 addition & 4 deletions x/crosschain/keeper/msg_server_tss_voter.go
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,5 @@ func (k msgServer) CreateTSSVoter(goCtx context.Context, msg *types.MsgCreateTSS
// IsAuthorizedNodeAccount checks whether a signer is authorized to sign , by checking their address against the observer mapper which contains the observer list for the chain and type
func (k Keeper) IsAuthorizedNodeAccount(ctx sdk.Context, address string) bool {
_, found := k.zetaObserverKeeper.GetNodeAccount(ctx, address)
if found {
return true
}
return false
return found
}

0 comments on commit b1598c7

Please sign in to comment.