diff --git a/frontend/src/components/TransactionRows/Name.spec.js b/frontend/src/components/TransactionRows/Name.spec.js index 2c370bafc..99e586fde 100644 --- a/frontend/src/components/TransactionRows/Name.spec.js +++ b/frontend/src/components/TransactionRows/Name.spec.js @@ -8,11 +8,9 @@ const routerPushMock = jest.fn() const mocks = { $router: { push: routerPushMock, - history: { - current: { - fullPath: '/transactions', - }, - }, + }, + $route: { + path: '/transactions', }, } diff --git a/frontend/src/components/TransactionRows/Name.vue b/frontend/src/components/TransactionRows/Name.vue index 8695645d8..b4ddfc849 100644 --- a/frontend/src/components/TransactionRows/Name.vue +++ b/frontend/src/components/TransactionRows/Name.vue @@ -34,8 +34,8 @@ export default { }, }, methods: { - tunnelEmail() { - if (this.$router.history.current.fullPath !== '/send') this.$router.push({ path: '/send' }) + async tunnelEmail() { + if (this.$route.path !== '/send') await this.$router.push({ path: '/send' }) this.$router.push({ query: { gradidoID: this.linkedUser.gradidoID } }) }, },