fix: await initApp() + fulltextSearch for reliable restore
This commit is contained in:
@@ -261,7 +261,7 @@ window.doLogin = async function() {
|
||||
var p = document.getElementById('login-pass').value;
|
||||
if (await loginUser(u, p)) {
|
||||
document.getElementById('sidebar').style.display = 'flex';
|
||||
initApp();
|
||||
await initApp();
|
||||
} else {
|
||||
document.getElementById('login-err').style.display = 'block';
|
||||
}
|
||||
@@ -347,7 +347,7 @@ async function initApp() {
|
||||
moduleListEl.style.display = 'none';
|
||||
searchResultsEl.style.display = 'block';
|
||||
searchResultsEl.innerHTML = '<p style="font-size:13px;color:#888">Restoring search...</p>';
|
||||
fulltextSearch(savedQ);
|
||||
await fulltextSearch(savedQ);
|
||||
} else {
|
||||
// Load initial module from hash or default
|
||||
var hash = location.hash.slice(1);
|
||||
|
||||
Reference in New Issue
Block a user