From 98ff4eab6748fc5b74dddee23db13ad3fc9ee87b Mon Sep 17 00:00:00 2001 From: Thomas Citharel Date: Mon, 23 Sep 2019 11:33:13 +0200 Subject: [PATCH] Fix event deletion redirection Closes #170 Signed-off-by: Thomas Citharel --- js/src/mixins/event.ts | 2 +- js/src/views/Event/Event.vue | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/js/src/mixins/event.ts b/js/src/mixins/event.ts index 05af58fb0..c6c361de2 100644 --- a/js/src/mixins/event.ts +++ b/js/src/mixins/event.ts @@ -35,7 +35,6 @@ export default class EventMixin extends mixins(Vue) { } private async deleteEvent(event: IEvent, currentActor: IPerson) { - const router = this.$router; const eventTitle = event.title; try { @@ -54,6 +53,7 @@ export default class EventMixin extends mixins(Vue) { position: 'is-bottom-right', duration: 5000, }); + await this.$router.push({ name: RouteName.HOME }); } catch (error) { console.error(error); } diff --git a/js/src/views/Event/Event.vue b/js/src/views/Event/Event.vue index ed468c0a9..34bb6fd20 100644 --- a/js/src/views/Event/Event.vue +++ b/js/src/views/Event/Event.vue @@ -260,7 +260,6 @@ export default class Event extends EventMixin { */ async openDeleteEventModalWrapper() { await this.openDeleteEventModal(this.event, this.currentActor); - await this.$router.push({ name: RouteName.HOME }); } async reportEvent(content: string, forward: boolean) {