aboutsummaryrefslogtreecommitdiffstats
path: root/packages/migrations
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2018-07-14 02:12:37 +0800
committerGitHub <noreply@github.com>2018-07-14 02:12:37 +0800
commite2438330f588eba03d50c18943b24d6e7f9e9479 (patch)
tree33ba5ae3919d67c6a5faa7b0ed07249fa5b8d694 /packages/migrations
parent9b387b8ec3c543b5c96d1887550797a2bb90fe94 (diff)
parent2f0a9148387b66d75b9ee3856e68f0ed3aa149de (diff)
downloaddexon-0x-contracts-e2438330f588eba03d50c18943b24d6e7f9e9479.tar.gz
dexon-0x-contracts-e2438330f588eba03d50c18943b24d6e7f9e9479.tar.zst
dexon-0x-contracts-e2438330f588eba03d50c18943b24d6e7f9e9479.zip
Merge pull request #874 from 0xProject/fix/request-timeout-issue
Fix Fetch Timeout Issue
Diffstat (limited to 'packages/migrations')
-rw-r--r--packages/migrations/package.json3
-rw-r--r--packages/migrations/src/utils/provider_factory.ts12
2 files changed, 4 insertions, 11 deletions
diff --git a/packages/migrations/package.json b/packages/migrations/package.json
index 0b7ab8ae2..d4aa73912 100644
--- a/packages/migrations/package.json
+++ b/packages/migrations/package.json
@@ -60,8 +60,7 @@
"@ledgerhq/hw-app-eth": "^4.3.0",
"ethereum-types": "^0.0.2",
"ethers": "3.0.22",
- "lodash": "^4.17.4",
- "web3-provider-engine": "14.0.6"
+ "lodash": "^4.17.4"
},
"optionalDependencies": {
"@ledgerhq/hw-transport-node-hid": "^4.3.0"
diff --git a/packages/migrations/src/utils/provider_factory.ts b/packages/migrations/src/utils/provider_factory.ts
index 7a217b1e0..5f69b258d 100644
--- a/packages/migrations/src/utils/provider_factory.ts
+++ b/packages/migrations/src/utils/provider_factory.ts
@@ -1,10 +1,8 @@
-import { LedgerEthereumClient, LedgerSubprovider } from '@0xproject/subproviders';
+import { LedgerEthereumClient, LedgerSubprovider, RPCSubprovider, Web3ProviderEngine } from '@0xproject/subproviders';
import Eth from '@ledgerhq/hw-app-eth';
// tslint:disable:no-implicit-dependencies
import TransportNodeHid from '@ledgerhq/hw-transport-node-hid';
import { Provider } from 'ethereum-types';
-import ProviderEngine = require('web3-provider-engine');
-import RpcSubprovider = require('web3-provider-engine/subproviders/rpc');
import { constants } from './constants';
@@ -15,18 +13,14 @@ async function ledgerEthereumNodeJsClientFactoryAsync(): Promise<LedgerEthereumC
}
export const providerFactory = {
async getLedgerProviderAsync(): Promise<Provider> {
- const provider = new ProviderEngine();
+ const provider = new Web3ProviderEngine();
const ledgerWalletConfigs = {
networkId: constants.KOVAN_NETWORK_ID,
ledgerEthereumClientFactoryAsync: ledgerEthereumNodeJsClientFactoryAsync,
};
const ledgerSubprovider = new LedgerSubprovider(ledgerWalletConfigs);
provider.addProvider(ledgerSubprovider);
- provider.addProvider(
- new RpcSubprovider({
- rpcUrl: constants.RPC_URL,
- }),
- );
+ provider.addProvider(new RPCSubprovider(constants.RPC_URL));
provider.start();
return provider;
},