From 0b3d6ef3120cd2568b14e370f3a2be3c8c69c443 Mon Sep 17 00:00:00 2001 From: Szymon Lesisz Date: Wed, 5 Sep 2018 15:44:47 +0200 Subject: [PATCH] removed Web3Service (unused) --- src/services/Web3Service.js | 28 ---------------------------- src/services/index.js | 1 - 2 files changed, 29 deletions(-) delete mode 100644 src/services/Web3Service.js diff --git a/src/services/Web3Service.js b/src/services/Web3Service.js deleted file mode 100644 index 996e9984..00000000 --- a/src/services/Web3Service.js +++ /dev/null @@ -1,28 +0,0 @@ -/* @flow */ - - -import TrezorConnect, { TRANSPORT } from 'trezor-connect'; -import * as WEB3 from 'actions/constants/web3'; - -import type { - Middleware, - MiddlewareAPI, - MiddlewareDispatch, - Action, -} from 'flowtype'; - -/** - * Middleware - */ -const Web3Service: Middleware = (api: MiddlewareAPI) => (next: MiddlewareDispatch) => (action: Action): Action => { - // pass action - next(action); - - if (action.type === WEB3.START) { - api.dispatch(WalletActions.clearUnavailableDevicesData(prevState, action.device)); - } - - return action; -}; - -export default Web3Service; \ No newline at end of file diff --git a/src/services/index.js b/src/services/index.js index d8aef7c9..b2ed5a5b 100644 --- a/src/services/index.js +++ b/src/services/index.js @@ -4,7 +4,6 @@ import RouterService from './RouterService'; import LocalStorageService from './LocalStorageService'; import CoinmarketcapService from './CoinmarketcapService'; import TrezorConnectService from './TrezorConnectService'; -import Web3Service from './Web3Service'; export default [ WalletService,