File tree Expand file tree Collapse file tree 5 files changed +116
-79
lines changed Expand file tree Collapse file tree 5 files changed +116
-79
lines changed Original file line number Diff line number Diff line change 30
30
"make-dir" : " ^1.3.0" ,
31
31
"markdownlint" : " ^0.8.1" ,
32
32
"markdownlint-cli" : " ^0.8.1" ,
33
- "nw" : " ^0.31.4 " ,
33
+ "nw" : " ^0.31.5 " ,
34
34
"nw-builder" : " ^3.5.4" ,
35
35
"replace-in-file" : " ^3.4.0" ,
36
36
"rimraf" : " ^2.6.2"
Original file line number Diff line number Diff line change @@ -82,19 +82,16 @@ cwc.Cache.prototype.update = async function(version) {
82
82
this . log_ . info ( 'Updating Cache to version' , this . version ) ;
83
83
await this . database_ . clear ( ) ;
84
84
85
- let promises = [ ] ;
86
85
this . log_ . info ( 'Loading external frameworks ...' ) ;
87
- promises . push ( this . loadFiles ( cwc . framework . External ) ) ;
86
+ await this . loadFiles ( cwc . framework . External ) ;
88
87
89
88
this . log_ . info ( 'Loading internal frameworks ...' ) ;
90
- promises . push ( this . loadFiles ( cwc . framework . Internal ) ) ;
89
+ await this . loadFiles ( cwc . framework . Internal ) ;
91
90
92
91
this . log_ . info ( 'Loading Style Sheets ...' ) ;
93
- promises . push ( this . loadFiles ( cwc . framework . StyleSheet ) ) ;
94
-
95
- promises . push ( this . database_ . add ( '__version__' , this . version ) ) ;
92
+ await this . loadFiles ( cwc . framework . StyleSheet ) ;
96
93
97
- await Promise . all ( promises ) ;
94
+ await this . database_ . add ( '__version__' , this . version ) ;
98
95
} ;
99
96
100
97
Original file line number Diff line number Diff line change @@ -282,7 +282,7 @@ cwc.ui.Builder.prototype.decorateUI = function() {
282
282
this . setProgressFunc ( 'Prepare account support ...' , this . prepareAccount ) ;
283
283
}
284
284
this . setProgressFunc ( 'Loading select screen ...' , this . showSelectScreen ) ;
285
- let startCwC = ( ) => {
285
+ this . setProgressFunc ( 'Loading cache ...' , this . loadCache ) . then ( ( ) => {
286
286
// Done.
287
287
this . setProgress ( 'Starting Coding with Chrome' , 100 ) ;
288
288
this . loaded = true ;
@@ -292,12 +292,8 @@ cwc.ui.Builder.prototype.decorateUI = function() {
292
292
this . events_ . clear ( ) ;
293
293
this . loadingScreen_ . hideSecondsAfterStart ( 3000 ) ;
294
294
resolve ( ) ;
295
- } ;
296
- this . setProgressFunc ( 'Loading cache ...' , this . loadCache ) . then ( ( ) => {
297
- startCwC ( ) ;
298
295
} ) . catch ( ( error ) => {
299
296
this . log_ . error ( 'Failed to load cache' , error ) ;
300
- startCwC ( ) ;
301
297
} ) ;
302
298
} ) ;
303
299
} ;
You can’t perform that action at this time.
0 commit comments