Rewrite the toggleMenu call

This commit is contained in:
Wolfgang Huß 2019-09-23 12:08:06 +02:00
parent 5b6f816ae1
commit da5c63e97d

View File

@ -14,10 +14,8 @@
primary
icon="bell"
@click.prevent="
() => {
toggleMenu()
updateNotifications()
}
toggleMenu()
updateNotifications()
"
>
{{ unreadNotifications }}
@ -65,7 +63,7 @@ export default {
} = await this.$apollo.mutate({
mutation: notificationQuery(this.$i18n),
})
// add all the new notifications to the notifications
// add all the new notifications to the old notifications at top of the list
if (notifications) {
notifications.forEach(udatedListNotification => {
const sameNotification = this.notifications.find(function(oldListNotification) {
@ -115,9 +113,6 @@ export default {
}
return countUnread
},
clickMenuButton() {
toggleMenu()
},
},
apollo: {
notifications: {