Whilst you're in here, can you make this `if (fileNames.length === 0) {` as that reads easier.