@@ -18,7 +18,6 @@ import { Notification } from "./store/Notification";
1818import { Qr } from "./store/Qr" ;
1919import { Advisor } from "./store/Advisor" ;
2020import { Dropbox , Drive , OneDrive } from "./models/backup" ;
21- import { EntryStorage } from "./models/storage" ;
2221
2322async function init ( ) {
2423 // Add globals
@@ -62,27 +61,12 @@ async function init() {
6261
6362 // Prompt for password if needed
6463 if ( instance . $store . state . accounts . shouldShowPassphrase ) {
65- instance . $store . commit ( "style/showInfo" , true ) ;
6664 // If we have cached password, use that
6765 if ( instance . $store . state . accounts . encryption . getEncryptionStatus ( ) ) {
6866 instance . $store . commit ( "currentView/changeView" , "LoadingPage" ) ;
69- for ( const entry of instance . $store . state . accounts . entries ) {
70- await entry . applyEncryption ( instance . $store . state . accounts . encryption ) ;
71- }
72- instance . $store . commit (
73- "accounts/updateExport" ,
74- await EntryStorage . getExport ( instance . $store . state . accounts . entries )
75- ) ;
76- instance . $store . commit (
77- "accounts/updateEncExport" ,
78- await EntryStorage . getExport (
79- instance . $store . state . accounts . entries ,
80- true
81- )
82- ) ;
83- instance . $store . commit ( "accounts/updateCodes" ) ;
84- instance . $store . commit ( "style/hideInfo" , true ) ;
67+ await instance . $store . dispatch ( "accounts/updateEntries" ) ;
8568 } else {
69+ instance . $store . commit ( "style/showInfo" , true ) ;
8670 instance . $store . commit ( "currentView/changeView" , "EnterPasswordPage" ) ;
8771 }
8872 }
0 commit comments