-
Notifications
You must be signed in to change notification settings - Fork 257
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Feat/update get top profitable wallet per token return object (#1222)
* feat: Update getTopProfitableWalletPerToken return type * fix: patch description
- Loading branch information
Showing
5 changed files
with
119 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'@moralisweb3/common-evm-utils': patch | ||
'@moralisweb3/evm-api': patch | ||
'moralis': patch | ||
--- | ||
|
||
Update `getTopProfitableWalletPerToken` return objects. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
packages/common/evmUtils/src/generated/types/EvmUnavailableChainNetWorth.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
// $ref: #/components/schemas/unavailableChainNetWorth | ||
// type: unavailableChainNetWorth | ||
// properties: | ||
// - chain_id ($ref: #/components/schemas/unavailableChainNetWorth/properties/chain_id) | ||
|
||
export interface EvmUnavailableChainNetWorthJSON { | ||
readonly chain_id: string; | ||
} | ||
|
||
export interface EvmUnavailableChainNetWorthInput { | ||
readonly chainId: string; | ||
} | ||
|
||
export class EvmUnavailableChainNetWorth { | ||
public static create(input: EvmUnavailableChainNetWorthInput | EvmUnavailableChainNetWorth): EvmUnavailableChainNetWorth { | ||
if (input instanceof EvmUnavailableChainNetWorth) { | ||
return input; | ||
} | ||
return new EvmUnavailableChainNetWorth(input); | ||
} | ||
|
||
public static fromJSON(json: EvmUnavailableChainNetWorthJSON): EvmUnavailableChainNetWorth { | ||
const input: EvmUnavailableChainNetWorthInput = { | ||
chainId: json.chain_id, | ||
}; | ||
return EvmUnavailableChainNetWorth.create(input); | ||
} | ||
|
||
/** | ||
* @description The chain id | ||
*/ | ||
public readonly chainId: string; | ||
|
||
private constructor(input: EvmUnavailableChainNetWorthInput) { | ||
this.chainId = input.chainId; | ||
} | ||
|
||
public toJSON(): EvmUnavailableChainNetWorthJSON { | ||
return { | ||
chain_id: this.chainId, | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7b334bf
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test coverage