add "testnet" field to config, and filter those values for "dev build" only

pull/260/head
Szymon Lesisz 6 years ago
parent 85ec63b779
commit fc4ff5d71c

@ -3,6 +3,7 @@
{
"type": "ripple",
"name": "Ripple Testnet",
"testnet": true,
"symbol": "XRP",
"shortcut": "xrp",
"bip44": "m/44'/144'/a'/0/0",
@ -52,6 +53,7 @@
{
"type": "ethereum",
"name": "Ethereum Ropsten",
"testnet": true,
"symbol": "tROP",
"shortcut": "trop",
"chainId": 3,

@ -141,10 +141,9 @@ const loadJSON = (): AsyncAction => async (dispatch: Dispatch): Promise<void> =>
try {
const config: Config = await httpRequest(AppConfigJSON, 'json');
// remove ropsten testnet from config networks
// remove testnets from config networks
if (!buildUtils.isDev()) {
const index = config.networks.findIndex(c => c.shortcut === 'trop');
delete config.networks[index];
config.networks = config.networks.filter(n => !n.testnet);
}
const ERC20Abi = await httpRequest(Erc20AbiJSON, 'json');

@ -8,6 +8,7 @@ import type { Action } from 'flowtype';
export type Network = {
type: string;
name: string;
testnet?: boolean;
shortcut: string;
symbol: string;
bip44: string;

Loading…
Cancel
Save