From 9b808669926e67564e46e8571c4417ca3e95b525 Mon Sep 17 00:00:00 2001 From: apanizo Date: Wed, 17 Oct 2018 17:25:47 +0200 Subject: [PATCH] Including network in safe route container as a prop --- src/routes/safe/container/index.jsx | 10 ++++++++-- src/routes/safe/container/selector.js | 4 +++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/routes/safe/container/index.jsx b/src/routes/safe/container/index.jsx index b980ec2a..27925d0d 100644 --- a/src/routes/safe/container/index.jsx +++ b/src/routes/safe/container/index.jsx @@ -47,13 +47,19 @@ class SafeView extends React.PureComponent { render() { const { - safe, provider, activeTokens, granted, userAddress, + safe, provider, activeTokens, granted, userAddress, network, } = this.props return ( { granted - ? + ? : } diff --git a/src/routes/safe/container/selector.js b/src/routes/safe/container/selector.js index 8c565663..45e9d3af 100644 --- a/src/routes/safe/container/selector.js +++ b/src/routes/safe/container/selector.js @@ -2,7 +2,7 @@ import { List } from 'immutable' import { createSelector, createStructuredSelector, type Selector } from 'reselect' import { safeSelector, type RouterProps, type SafeSelectorProps } from '~/routes/safe/store/selectors' -import { providerNameSelector, userAccountSelector } from '~/logic/wallets/store/selectors' +import { providerNameSelector, userAccountSelector, networkSelector } from '~/logic/wallets/store/selectors' import { type Safe } from '~/routes/safe/store/model/safe' import { type Owner } from '~/routes/safe/store/model/owner' import { type GlobalState } from '~/store' @@ -15,6 +15,7 @@ export type SelectorProps = { provider: string, activeTokens: List, userAddress: string, + network: string, } export const grantedSelector: Selector = createSelector( @@ -44,4 +45,5 @@ export default createStructuredSelector({ activeTokens: activeTokensSelector, granted: grantedSelector, userAddress: userAccountSelector, + network: networkSelector, })