Wait for the modules directory to be created before writing module files
Summary: Typo: the operation of writing module files to a common sub-directory didn?t wait until that directory was created, because `Promise.all` was invoked directly as argument to `.then()`, rather than putting it in a lambda function. Reviewed By: andreicoman11 Differential Revision: D3150338 fb-gh-sync-id: c65270b1757a248993048b039f5ebadb281b2eea fbshipit-source-id: c65270b1757a248993048b039f5ebadb281b2eea
This commit is contained in:
Родитель
a1e105eea5
Коммит
b8da6a2963
|
@ -41,7 +41,7 @@ function saveAsAssets(bundle, options, log) {
|
|||
const modulesDir = path.join(path.dirname(bundleOutput), MODULES_DIR);
|
||||
const writeUnbundle =
|
||||
createDir(modulesDir).then( // create the modules directory first
|
||||
Promise.all([
|
||||
() => Promise.all([
|
||||
writeModules(modules, modulesDir, encoding),
|
||||
writeFile(bundleOutput, startupCode, encoding),
|
||||
writeMagicFlagFile(modulesDir),
|
||||
|
|
Загрузка…
Ссылка в новой задаче