From 5ad47b1a2490b84877f63f887e8713a0e28a73fd Mon Sep 17 00:00:00 2001 From: "glevi@fb.com" Date: Thu, 25 May 2017 22:54:51 -0700 Subject: [PATCH] Deploy v0.47.0 to xplat/js Reviewed By: zertosh Differential Revision: D5135644 fbshipit-source-id: f979970f8d0c4e082ec1302084d4def6652557c8 --- .../node-haste/DependencyGraph/ResolutionRequest.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/packages/metro-bundler/src/node-haste/DependencyGraph/ResolutionRequest.js b/packages/metro-bundler/src/node-haste/DependencyGraph/ResolutionRequest.js index dfe0e6f2..4196c378 100644 --- a/packages/metro-bundler/src/node-haste/DependencyGraph/ResolutionRequest.js +++ b/packages/metro-bundler/src/node-haste/DependencyGraph/ResolutionRequest.js @@ -296,6 +296,12 @@ class ResolutionRequest { return result; } + function resolveKeyWithPromise( + [key: TModule, promise: Promise>], + ): Promise<[TModule, Array]> { + return promise.then(value => [key, value]); + } + return Promise.all([ // kicks off recursive dependency discovery, but doesn't block until it's // done @@ -901,10 +907,6 @@ function resolveWindowsPath(modulePath) { return path.resolve(modulePath); } -function resolveKeyWithPromise([key, promise]) { - return promise.then(value => [key, value]); -} - function isRelativeImport(filePath) { return /^[.][.]?(?:[/]|$)/.test(filePath); }