@davoodmehraban89 / Factor-easy-2 Mirror · read-only / commits / 0200f5c
Fork 0

سامانه صدور فاکتور و حسابداری

Mirrored from https://github.com/davoodmehraban89/Factor-easy.git

Synced Dec 4, 03:00 UTC

fix(login): release authenticated modules without holding login form

davoodmehraban89 committed Oct 12, 2026 at 19:37 UTC 0200f5cfc7817d6061dcbb1d6b12dec62a661711
1 file changed +8 -8
js/bootstrap.js
+8 -8
@@ -41,15 +41,15 @@ window.addEventListener('DOMContentLoaded',async()=>{
41 const started=performance.now();
42 const results=await Promise.allSettled(FINORA_EXTENSION_SCRIPTS.map(finoraLoadScript));
43 const failed=results.flatMap((r,i)=>r.status==='rejected'?[FINORA_EXTENSION_SCRIPTS[i]]:[]);
44 - window.FinoraStartupStatus={
44 + Object.assign(window.FinoraStartupStatus,{
45 extensionCount:FINORA_EXTENSION_SCRIPTS.length,
46 failedExtensionCount:failed.length,
47 - extensionLoadMs:Math.round(performance.now()-started)
48 - };
47 + extensionLoadMs:Math.round(performance.now()-started),
48 + extensionsReady:true
49 + });
50 if(failed.length)console.error('Finora platform extension assets unavailable:',failed);
50 - // Never start a restored user session against half-loaded application modules.
51 - if(!currentUser)await initAuthSystem();
52 - // UI fixtures and diagnostics may now wait for the completed session check.
53 - // This flag contains no session/identity information.
54 - window.FinoraStartupStatus.authChecked=true;
51 + // A successful sign-in/restored session must wait for these modules, but
52 + // rendering the interactive email/password form never waits for them.
53 + window.finoraMarkAppAssetsReady();
54 + if(window.FinoraStartupStatus.authSessionChecked)window.FinoraStartupStatus.authChecked=true;
55 });