File tree 1 file changed +5
-2
lines changed
1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -143,7 +143,8 @@ export class PwaAssetGenerator extends AssetGenerator {
143
143
const destDir = join ( pwaAssetDir , PWA_ASSET_PATH ) ;
144
144
try {
145
145
await mkdirp ( destDir ) ;
146
- } catch {
146
+ } catch ( e ) {
147
+ console . log ( e ) ;
147
148
// ignore error
148
149
}
149
150
@@ -364,7 +365,9 @@ export class PwaAssetGenerator extends AssetGenerator {
364
365
// Delete icons that were replaced
365
366
for ( const icon of icons ) {
366
367
if ( await pathExists ( join ( pwaDir , icon . src ) ) ) {
367
- const exists = ! ! pwaAssets . find ( ( i : any ) => i . sizes === icon . sizes ) ;
368
+ const exists = ! ! pwaAssets . find ( ( { template : { width, height } } ) => {
369
+ return `${ width } x${ height } ` === icon . sizes
370
+ } ) ;
368
371
if ( ! exists ) {
369
372
rmSync ( join ( pwaDir , icon . src ) ) ;
370
373
warn ( `DELETE ${ icon . src } ` ) ;
You can’t perform that action at this time.
0 commit comments