refactor: change how ready and logged in are controlled
This commit is contained in:
parent
37a03e41ca
commit
ea22848868
|
@ -59,10 +59,17 @@ export function useBrowserState() {
|
|||
}
|
||||
|
||||
async function boot() {
|
||||
const lume = useLume();
|
||||
|
||||
const reg = await navigator.serviceWorker.register("/sw.js");
|
||||
await reg.update();
|
||||
|
||||
await kernel.serviceWorkerReady();
|
||||
|
||||
kernel.init().then(() => {
|
||||
lume.setReady(true);
|
||||
});
|
||||
|
||||
await kernelLoaded();
|
||||
|
||||
BOOT_FUNCTIONS.push(
|
||||
|
@ -101,6 +108,8 @@ async function boot() {
|
|||
|
||||
await bootup();
|
||||
|
||||
lume.setIsLoggedIn(true);
|
||||
|
||||
await Promise.all([
|
||||
ethClient.ready(),
|
||||
handshakeClient.ready(),
|
||||
|
|
Loading…
Reference in New Issue