pull/513/head
Vladimir Volek 5 years ago
parent a600266786
commit 88394eede2

@ -379,8 +379,6 @@ export const handleCoinVisibility = (
newConfig = [...configuration, coinShortcut]; newConfig = [...configuration, coinShortcut];
} }
console.log(coinShortcut, shouldBeVisible, isExternal);
if (isExternal) { if (isExternal) {
storageUtils.set(TYPE, KEY_HIDDEN_COINS_EXTERNAL, JSON.stringify(newConfig)); storageUtils.set(TYPE, KEY_HIDDEN_COINS_EXTERNAL, JSON.stringify(newConfig));
dispatch({ dispatch({
@ -402,9 +400,6 @@ export const toggleGroupCoinsVisibility = (
isExternal: boolean isExternal: boolean
): ThunkAction => (dispatch: Dispatch) => { ): ThunkAction => (dispatch: Dispatch) => {
// supported coins // supported coins
console.log('checked', checked);
if (checked && !isExternal) { if (checked && !isExternal) {
dispatch({ dispatch({
type: WALLET.SET_HIDDEN_COINS, type: WALLET.SET_HIDDEN_COINS,

@ -56,11 +56,11 @@ class CoinMenu extends PureComponent<Props> {
} }
getOtherCoins() { getOtherCoins() {
const { hiddenCoins } = this.props.wallet; const { hiddenCoinsExternal } = this.props.wallet;
return coins return coins
.sort((a, b) => a.order - b.order) .sort((a, b) => a.order - b.order)
.filter(item => !item.isHidden) // hide coins globally in config .filter(item => !item.isHidden) // hide coins globally in config
.filter(item => !hiddenCoins.includes(item.id)) .filter(item => !hiddenCoinsExternal.includes(item.id))
.map(coin => { .map(coin => {
const row = ( const row = (
<RowCoin <RowCoin
@ -102,10 +102,10 @@ class CoinMenu extends PureComponent<Props> {
} }
isBottomMenuEmpty() { isBottomMenuEmpty() {
const { hiddenCoins } = this.props.wallet; const { hiddenCoinsExternal } = this.props.wallet;
const numberOfVisibleNetworks = coins const numberOfVisibleNetworks = coins
.filter(item => !item.isHidden) .filter(item => !item.isHidden)
.filter(item => !hiddenCoins.includes(item.id)); .filter(item => !hiddenCoinsExternal.includes(item.id));
return numberOfVisibleNetworks.length <= 0; return numberOfVisibleNetworks.length <= 0;
} }

@ -111,9 +111,6 @@ class CoinsSettings extends PureComponent<Props, State> {
<Wrapper> <Wrapper>
<Row> <Row>
<Content> <Content>
{console.log('hidden coins', props.hiddenCoins)}
{console.log('hidden coins', props.hiddenCoins)}
{console.log('hidden coins external', props.hiddenCoinsExternal)}
<Label> <Label>
<Left> <Left>
<FormattedMessage {...l10nMessages.TR_VISIBLE_COINS} /> <FormattedMessage {...l10nMessages.TR_VISIBLE_COINS} />

Loading…
Cancel
Save