Skip to content

Commit

Permalink
fix($eslint): pass eslint line size check
Browse files Browse the repository at this point in the history
  • Loading branch information
faceyspacey authored Aug 18, 2017
1 parent cbfb558 commit 516fadc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/flushChunks.js
Original file line number Diff line number Diff line change
Expand Up @@ -191,19 +191,19 @@ const concatFilesAtKeys = (

const filesFromChunks = (
chunkNames: Files,
assetsByChunkName: FilesMap,
assets: FilesMap,
checkChunkNames?: boolean
): Files => {
const hasChunk = entry => {
const result = !!(assetsByChunkName[entry] || assetsByChunkName[entry+'-'])
const result = !!(assets[entry] || assets[entry+'-'])
if (!result && checkChunkNames) {
console.warn(`[FLUSH CHUNKS]: Unable to find ${entry} in Webpack chunks. Please check usage of Babel plugin.`)
}

return result
}

const entryToFiles = entry => assetsByChunkName[entry] || assetsByChunkName[entry+'-']
const entryToFiles = entry => assets[entry]|| assets[entry+'-']

return [].concat(...chunkNames.filter(hasChunk).map(entryToFiles))
}
Expand Down

0 comments on commit 516fadc

Please sign in to comment.