Skip to content

Commit 9a24f39

Browse files
committed
[[settings]] bug when accessing missing subViews
1 parent 5443f6c commit 9a24f39

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

src/packages/settings/About.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ let currentVersion = browser.runtime.getManifest().version
77
<p>Current Patchfox Version is <i>{currentVersion}</i>.</p>
88
<p>Source code is available at:</p>
99
<ul>
10-
<li><a href="https://github.com/soapdog/patchfox">Github</a></li>
11-
<li><a href="https://git.sr.ht/~soapdog/patchfox">Sourcehut</a></li>
10+
<li><a href="https://github.com/soapdog/patchfox">GitHub</a></li>
11+
<li><a href="https://git.sr.ht/~soapdog/patchfox">SourceHut</a></li>
1212
</ul>
1313
</div>

src/packages/settings/Settings.svelte

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,11 @@
2020
2121
export let subView = "identitiesAndConnections"
2222
23+
if (!views.hasOwnProperty(subView)) {
24+
console.log("no such subview", subView)
25+
subView = "about"
26+
}
27+
2328
const handleMenuChange = ev => {
2429
subView = ev.detail.subView
2530
}

0 commit comments

Comments
 (0)