From 87c47bc83d3ab87130baa438611ff763d39a5a3f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Wolfgang=20Hu=C3=9F?= Date: Thu, 1 Jun 2023 17:11:05 +0200 Subject: [PATCH] Update webapp/components/FilterMenu/OrderByFilter.vue Co-authored-by: Hannes Heine --- .../components/FilterMenu/OrderByFilter.vue | 20 +++---------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/webapp/components/FilterMenu/OrderByFilter.vue b/webapp/components/FilterMenu/OrderByFilter.vue index 799b5e199..5670669a9 100644 --- a/webapp/components/FilterMenu/OrderByFilter.vue +++ b/webapp/components/FilterMenu/OrderByFilter.vue @@ -63,28 +63,14 @@ export default { } }, buttonTitle(buttonType) { - let title switch (buttonType) { case 'asc': - if (this.orderedByCreationDate) { - title = this.$t('filter-menu.order.oldest.hint') - } else { - title = this.$t('filter-menu.order.last.hint') - } - break + return this.orderedByCreationDate ? this.$t('filter-menu.order.oldest.hint') : this.$t('filter-menu.order.last.hint') case 'desc': - if (this.orderedByCreationDate) { - title = this.$t('filter-menu.order.newest.hint') - } else { - title = this.$t('filter-menu.order.next.hint') - } - break - + return this.orderedByCreationDate ? this.$t('filter-menu.order.newest.hint') : this.$t('filter-menu.order.next.hint') default: - title = '' - break + return '' } - return title }, }, }