From c56a51c4eb88ab20a620612222ecc7b8c8b3afcb Mon Sep 17 00:00:00 2001 From: James Gillmore Date: Tue, 4 Jul 2017 14:55:35 -0700 Subject: [PATCH] fix($cssChunksMap): fix edge case with missing css files --- src/flushChunks.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/flushChunks.js b/src/flushChunks.js index 255b043..ef7feb7 100644 --- a/src/flushChunks.js +++ b/src/flushChunks.js @@ -205,6 +205,7 @@ const createCssHash = ( publicPath: string ): CssChunksHash => Object.keys(assetsByChunkName).reduce((hash, name) => { + if (!assetsByChunkName[name]) return hash const file = assetsByChunkName[name].find(file => file.endsWith('.css')) if (file) hash[name] = `${publicPath}${file}` return hash