Fix loading wrong source if memorized framework demo is not given

This commit is contained in:
svenadlung 2021-11-22 22:29:59 +01:00
parent a55aa5fd17
commit 3c1f04bfe7

View File

@ -232,7 +232,7 @@ export default {
mounted() {
// TODO: load language from url params
const intitialTab = localStorage.tab ? localStorage.tab : this.sortedTabs[0]?.name
const intitialTab = localStorage.tab && this.sources[localStorage.tab] ? localStorage.tab : this.sortedTabs[0]?.name
this.setTab(intitialTab)
window.document.addEventListener('editor', this.onEditor, false)