File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -173,14 +173,14 @@ class LayerCache {
173173
174174 private async restoreLayers ( ) {
175175 const restoring = ( await this . getLayerIds ( ) ) . map ( layerId => this . restoreSingleLayerBy ( layerId ) )
176- const hasRestored = await Promise . all ( restoring )
177- const FailedToRestore = ( restored : Boolean ) => ! restored
178- return hasRestored . filter ( FailedToRestore ) . length === 0
176+ const restoredLayerKeysThatMayContainUndefined = await Promise . all ( restoring )
177+ core . debug ( JSON . stringify ( { hasRestored : restoredLayerKeysThatMayContainUndefined } ) )
178+ const FailedToRestore = ( restored : string | undefined ) => restored === undefined
179+ return restoredLayerKeysThatMayContainUndefined . filter ( FailedToRestore ) . length === 0
179180 }
180181
181- private async restoreSingleLayerBy ( id : string ) : Promise < boolean > {
182- const restoredCacheKeyMayUndefined = await cache . restoreCache ( [ this . genSingleLayerStorePath ( id ) ] , this . genSingleLayerStoreKey ( id ) )
183- return typeof restoredCacheKeyMayUndefined === `string`
182+ private async restoreSingleLayerBy ( id : string ) : Promise < string | undefined > {
183+ return await cache . restoreCache ( [ this . genSingleLayerStorePath ( id ) ] , this . genSingleLayerStoreKey ( id ) )
184184 }
185185
186186 private async loadImageFromUnpacked ( ) {
You can’t perform that action at this time.
0 commit comments