mirror of
https://github.com/huhu/rust-search-extension
synced 2024-11-13 23:27:13 +00:00
Fix auto prepend file://
to offline doc path
This commit is contained in:
parent
681e159d2c
commit
1014055803
2 changed files with 2 additions and 2 deletions
2
core
2
core
|
@ -1 +1 @@
|
|||
Subproject commit b1f68244f8f9a938b3f29fdd3dfb548cd88acb80
|
||||
Subproject commit 94d784a79113a1cca3b5ce4e83912894281ae137
|
|
@ -46,7 +46,7 @@ document.addEventListener('DOMContentLoaded', async function () {
|
|||
// Replace all "/" to "\" for Windows.
|
||||
path = event.target.value.replaceAll("/", "\\");
|
||||
}
|
||||
if (!path.startsWith("file://")) {
|
||||
if (path.startsWith("/")) {
|
||||
// Prepend file:// to allow browser open the file url
|
||||
path = "file://" + path;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue