Skip to content

Commit

Permalink
feat: Adding non-bitgo recovery support for bera
Browse files Browse the repository at this point in the history
Tikcet: COIN-4386
  • Loading branch information
mohitkh7 committed Jan 24, 2025
1 parent 480c0a2 commit 2661410
Show file tree
Hide file tree
Showing 7 changed files with 100 additions and 65 deletions.
8 changes: 8 additions & 0 deletions electron/main/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ import { Algo, Talgo } from '@bitgo/sdk-coin-algo';
import { EthLikeCoin, TethLikeCoin } from '@bitgo/sdk-coin-ethlike';
import { Sui, Tsui } from '@bitgo/sdk-coin-sui';
import { loadWebAssembly } from '@bitgo/sdk-opensslbytes';
import { Bera, Tbera } from '@bitgo/sdk-coin-bera';

const bip32 = BIP32Factory(ecc);

Expand Down Expand Up @@ -156,6 +157,8 @@ sdk.register('sui', Sui.createInstance);
sdk.register('tsui', Tsui.createInstance);
sdk.register('thorchain:rune', Rune.createInstance);
sdk.register('tthorchain:rune', Trune.createInstance);
sdk.register('bera', Bera.createInstance);
sdk.register('tbera', Tbera.createInstance);

Erc20Token.createTokenConstructors().forEach(({ name, coinConstructor }) => {
sdk.register(name, coinConstructor);
Expand Down Expand Up @@ -304,6 +307,11 @@ async function createWindow() {
case 'bsc':
case 'tbsc':
sdk = new BitGoAPI({ env: environment, bscscanApiToken: apiKey });
break;
case 'bera':
case 'tbera':
sdk = new BitGoAPI({ env: environment });
break;
default:
sdk = new BitGoAPI({ env: environment });
}
Expand Down
99 changes: 40 additions & 59 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"@bitgo/sdk-coin-avaxc": "5.2.8",
"@bitgo/sdk-coin-bch": "2.1.8",
"@bitgo/sdk-coin-bcha": "2.2.8",
"@bitgo/sdk-coin-bera": "^2.3.4",
"@bitgo/sdk-coin-bld": "3.0.27",
"@bitgo/sdk-coin-bsc": "22.2.11",
"@bitgo/sdk-coin-bsv": "2.1.8",
Expand Down
3 changes: 2 additions & 1 deletion scripts/build-icons.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ const coins = [
'algo',
'bsc',
'sui',
'thorchain:rune'
'thorchain:rune',
'bera'
];

const paths = fs
Expand Down
Loading

0 comments on commit 2661410

Please sign in to comment.