From 184bc106cd8db4e64ab0d8fa8185fa4159c8383c Mon Sep 17 00:00:00 2001 From: Richard Tibbles Date: Tue, 9 Apr 2024 10:28:00 -0700 Subject: [PATCH] Use router.replace for redirect. --- kolibri/plugins/learn/assets/src/views/TopicsContentPage.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kolibri/plugins/learn/assets/src/views/TopicsContentPage.vue b/kolibri/plugins/learn/assets/src/views/TopicsContentPage.vue index f26ba351864..7b5d14df349 100644 --- a/kolibri/plugins/learn/assets/src/views/TopicsContentPage.vue +++ b/kolibri/plugins/learn/assets/src/views/TopicsContentPage.vue @@ -164,7 +164,6 @@ import { AddDeviceForm } from 'kolibri.coreVue.componentSets.sync'; import { ContentNodeKinds, ContentErrorConstants } from 'kolibri.coreVue.vuex.constants'; import { crossComponentTranslator } from 'kolibri.utils.i18n'; - import redirectBrowser from 'kolibri.utils.redirectBrowser'; import samePageCheckGenerator from 'kolibri.utils.samePageCheckGenerator'; import client from 'kolibri.client'; import urls from 'kolibri.urls'; @@ -520,7 +519,7 @@ if (this.content) { const id = this.content.id; if (!this.isUserLoggedIn && (this.lessonId || this.classId)) { - redirectBrowser(window.location.href.split('?')[0]); + this.$router.replace({ ...this.$route, query: null }); } client({ method: 'get',