Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(tron): add trc10 test for ci (#33)
* fix(tron): add trc10 test for ci * fix(tron): add check balance * fix(tron): rm unused code
- Loading branch information
1 parent
ca42aff
commit dd35100
Showing
5 changed files
with
126 additions
and
46 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
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
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,13 @@ | ||
const TRX_ASSET_LENGTH = 3; | ||
const TRC10_ASSET_LENGTH = 7; | ||
|
||
export function getAssetTypeByAsset(asset: string): string { | ||
switch (asset.length) { | ||
case TRX_ASSET_LENGTH: | ||
return 'trx'; | ||
case TRC10_ASSET_LENGTH: | ||
return 'trc10'; | ||
default: | ||
return 'trc20'; | ||
} | ||
} |
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