Skip to content

Commit

Permalink
fix(payout-amounts): displaying tokens in payout-amounts (#2438)
Browse files Browse the repository at this point in the history
  • Loading branch information
evgenibir authored Sep 14, 2023
1 parent 3fc4b7e commit 42c014b
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions src/components/common/payout-amounts.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,12 @@ export default defineComponent({
methods: {
settingsHasToken(token) {
if (token !== 'Voice Token') {
const cleanTokenName = token.split(' ')?.[2]?.replace('(', '').replace(')', '')
return cleanTokenName === this.$store.state.dao.settings.pegToken || cleanTokenName === this.$store.state.dao.settings.rewardToken
if (token !== 'VOICE') {
if (this.$store.state.dao.settings.pegToken && this.$store.state.dao.settings.rewardToken) {
return token === this.$store.state.dao.settings.pegToken || token === this.$store.state.dao.settings.rewardToken
} else {
return false
}
} else {
return true
}
Expand All @@ -50,5 +53,5 @@ export default defineComponent({
.full-width(:class="{row: $q.platform.is.desktop}")
template(v-for="token in tokens")
.col(v-if="token.value" :class="{'col-12': stacked, 'q-mb-md': $q.platform.is.mobile}")
token-value(v-if="settingsHasToken(token.label)" :daoLogo="daoLogo" :multiplier="multiplier" v-bind="token")
token-value(v-if="settingsHasToken(token.symbol)" :daoLogo="daoLogo" :multiplier="multiplier" v-bind="token")
</template>

0 comments on commit 42c014b

Please sign in to comment.