throwing for unresolved modules: flip logic

Summary:
The current test checks whether the target platform is `'ios'`. When building with windows, errors will also be swallowed silently.

This adds a check whether the target platform is `'android'`, where we have to avoid throwing for FB-internal reasons.

Reviewed By: martinbigio

Differential Revision: D3907025

fbshipit-source-id: 5abeb06b9121265fe1aa3932ad1785f148f04ddf
This commit is contained in:
David Aurelio 2016-09-22 07:26:57 -07:00 committed by Facebook Github Bot
parent 9bb2082889
commit 7a3f44a2bd
1 changed files with 1 additions and 1 deletions

View File

@ -105,7 +105,7 @@ class Resolver {
preferNativePlatform: true,
fileWatcher: opts.fileWatcher,
cache: opts.cache,
shouldThrowOnUnresolvedErrors: (_, platform) => platform === 'ios',
shouldThrowOnUnresolvedErrors: (_, platform) => platform !== 'android',
transformCode: opts.transformCode,
extraNodeModules: opts.extraNodeModules,
assetDependencies: ['react-native/Libraries/Image/AssetRegistry'],