Граф коммитов

15290 Коммитов

Автор SHA1 Сообщение Дата
Andrew Chen (Eng) 17ced5701f Add test for WritableNativeMap
Summary: A simple test for WritableNativeMap. Also includes a test to verify that the key name exists in the error message if a dynamic cast exception occurs (this will be implemented in the future)

Reviewed By: mdvacca

Differential Revision: D12914375

fbshipit-source-id: 654674b1b32e7b3f38cc1364a2302d1ce08ec33e
2018-11-16 18:44:35 -08:00
Spencer Ahrens 6f34bc4016 Back out "reapply TextInput es6 conversion with fixes, attemps to fix"
Summary:
Back it out again. This time really not sure why this is breaking, but it seems to be production only. The error seems to be "RCTSinglelineTextInputView" was not found in the UIManager" but the relavent logic is not changed in this diff, just moved around, so unclear why it would trigger a failure.

Reverting to be safe. When we re-apply the diff, we'll need to test a full OTA to prod to verify the fix.

Reviewed By: blairvanderhoof

Differential Revision: D13108463

fbshipit-source-id: 5f877a0c1a08dc114ce45921d6d92bf619575977
2018-11-16 14:50:23 -08:00
Jonathan Lee 383ea9923a Add bounce method to TouchableBounce
Summary: Adds a `bounce` method that just bounces the element without invoking any callbacks.

Differential Revision: D13085800

fbshipit-source-id: 310b273b260c924fbde32bfad1de7226d068bd57
2018-11-16 12:03:29 -08:00
Panagiotis Vekris 8fb228f313 Flow v0.86.0 in xplat/js
Summary:
allow-large-files
bypass-lint
ignore-conflict-markers
ignore-signed-source
ignore-nocommit

drop-conflicts

Reviewed By: yungsters

Differential Revision: D13081129

fbshipit-source-id: fbb0ccaf3c0a2f224a56f6f6ac6c26811ebba583
2018-11-16 10:43:16 -08:00
empyrical 0c0540965a CxxReact: Silence 'unused lambda capture' warnings in open-source (#22240)
Summary:
This pull request silences build warnings like this in open-source:

```
{snip}/ReactCommon/cxxreact/CxxNativeModule.cpp:134:85: warning: lambda capture 'callId' is not used [-Wunused-lambda-capture]
  messageQueueThread_->runOnQueue([method, params=std::move(params), first, second, callId] () {
```

These are variables used by "fbsystrace", which is not open-sourced.

An  unused statement has been added to the affected files in the `#else` for the `#ifdef WITH_FBSYSTRACE` conditionals
Pull Request resolved: https://github.com/facebook/react-native/pull/22240

Differential Revision: D13031358

Pulled By: shergin

fbshipit-source-id: 8ccfc226b65e32abda6abb573f77a6589bd19dcd
2018-11-16 10:37:16 -08:00
Spencer Ahrens 9ea1295179 reapply TextInput es6 conversion with fixes, attemps to fix
Summary: D10515754 reapplied by backing out D12989604 and then fixed by manually forwarding the instance methods to the host function instead of using `forwardRef`. This also removes the need for the $flowFixMe.

Reviewed By: TheSavior

Differential Revision: D13048482

fbshipit-source-id: ff2447aff123e0960eddaef645f7dc976a426e14
2018-11-15 20:51:52 -08:00
Spencer Ahrens a00940693e New TextInput-test that would have prevented S168585
Summary: Adds a basic test that would have prevented S168585. We should expand coverage of this and other components as well.

Reviewed By: TheSavior

Differential Revision: D13038064

fbshipit-source-id: 14cf4742efd53d7bca2a3f8d1c5c34ebc6227674
2018-11-15 20:51:52 -08:00
Dulmandakh 673ef39561 resizeMode applies to Image.defaultSource (#22216)
Summary:
resizeMode applies to Image.defaultSource, because depending on screen resolution sometimes we see padding around defaultSource image while source loading. Now we can control scale of both source and defaultSource.

Changelog:
----------
[Android] [Fixed] - Image.resizeMode will apply to defaultSource, enhanced user experience. Previously, resizeMode didn't applied to defaultSource, therefore depending on screen resolution sometimes we see padding around defaultSource image while source loading.
Pull Request resolved: https://github.com/facebook/react-native/pull/22216

Differential Revision: D13088220

Pulled By: mdvacca

fbshipit-source-id: 92c66cf6228f3b7666b9ef2404d034f0005b5234
2018-11-15 20:37:16 -08:00
Valentin Shergin 271ace9e91 Defining explicit clang-format for Objective-C part of React Native
Summary:
Now, Objective-C part of RN is in `xplat` directory, so global Objective-C clang-format does not affect that.
Explicit clang-format is also useful for external contributors who don't have access to the rest of monorepo.
The actual rules are copy-paste from ReactCommon folder with small changes (like 120 characters max line length) that conform to regular Facebook code style and which make sense only for Objective-C.

Reviewed By: fkgozali

Differential Revision: D13093150

fbshipit-source-id: 79d64b4fba6eeb94e9b8d87ef9c3f86b3a5ed94e
2018-11-15 20:28:14 -08:00
Enrico Bern Hardy Tanuwidjaja 4aeea4d2dc Changed front-facing camera so that it shows consistent image during capture and preview
Summary: Changed front-facing camera so that it shows consistent image during capture and preview

Reviewed By: mmmulani

Differential Revision: D13012715

fbshipit-source-id: 043cd9178fc49ef9e8e628a866dd8e52434f7306
2018-11-15 16:28:03 -08:00
Tim Yung d9c2cdae41 JS: Switch from `new Buffer` to `Buffer.from`
Summary:
Constructing `Buffer` using the constructor [[https://nodesource.com/blog/understanding-the-buffer-deprecation-in-node-js-10/ | has been deprecated in Node 10 due to security considerations]].

This is a simple and straightforward conversion.

Reviewed By: mjesun

Differential Revision: D13080655

fbshipit-source-id: 100d8f28c3b255422b26e820aaadcc4f32f41e0d
2018-11-15 12:13:05 -08:00
gengjiawen 5939d078a0 Fix compatibility issue for android 16 device.Fixes #22294 (#22295)
Summary:
Fix compatibility issue for android 16 device. Related issue https://github.com/facebook/react-native/pull/22295.
pass all current ci.
none
 [GENERAL] [ANDROID] [Fixed] - Fix compatibility issue for android 16 device
Pull Request resolved: https://github.com/facebook/react-native/pull/22295

Differential Revision: D13084152

Pulled By: hramos

fbshipit-source-id: 42459ddc6f84f870affdda5ba19bcd8bb27b56d7
2018-11-15 09:58:13 -08:00
Brian Vaughn aacb06c594 Fix React Native AsyncMode and DevTools
Summary:
Fixes two problems I uncovered with React Native:
1. `FBCore/Prelude` points to `React.unstable_AsyncMode` which is not defined. (This type was renamed to `React.unstable_ConcurrentMode` in React v16.6.0. **As a result** people in the "react_native:async_rendering" GK will no longer get runtime errors on app start.
2. Updates `react-devtools` and (more importantly) `react-devtools-core` to 3.4.2 to handle the React-internal tag/type refactoring that happened prior to the release of 16.6.0. **As a result** DevTools will no longer cause a runtime error when connected to React Native.

For the second change, I ran `js1 upgrade react-devtools -v ^3.4.2`

Reviewed By: sebmarkbage

Differential Revision: D13030590

fbshipit-source-id: 603f7f6259f282839039820bcdba4310064a7965
2018-11-15 09:26:01 -08:00
David Aurelio 619de16661 Back to yearless format for MIT license
Summary:
@public

Restores the yearless format of the MIT license.

Reviewed By: SidharthGuglani

Differential Revision: D13082510

fbshipit-source-id: f5a849b06652cedf68547d4a7963398b2627915f
2018-11-15 08:24:57 -08:00
Igor Mandrigin b971c5beb8 Workaround a wrong fling direction for inverted ScrollViews on Android P (#21117)
Summary:
This is a safe workaround to an issue in Android P: https://issuetracker.google.com/issues/112385925

It is based on a fact that even though `fling` receive a wrong sign in `velocityY`, `mOnScrollDispatchHelper.getYFlingVelocity()` still returns a fling direction.

Fixes #19434
Pull Request resolved: https://github.com/facebook/react-native/pull/21117

Differential Revision: D13082740

Pulled By: hramos

fbshipit-source-id: 1b28586d2c7bdcae4a111d3cead4a0455cebb99a
2018-11-15 07:19:09 -08:00
Stephy Ma 984eef8f9e Revert D12994045: Flow v0.86.0 in xplat/js [3/n]
Differential Revision:
D12994045

Original commit changeset: 04552bf081ba

fbshipit-source-id: 062b367b88a966a6efc895c99e9911f0ec0fe8ff
2018-11-14 23:04:04 -08:00
Panagiotis Vekris 43ad3a64e6 Flow v0.86.0 in xplat/js [3/n]
Summary:
allow-large-files
bypass-lint
ignore-conflict-markers
ignore-signed-source
ignore-nocommit

drop-conflicts

Reviewed By: avikchaudhuri

Differential Revision: D12994045

fbshipit-source-id: 04552bf081ba742de58e80fba08f8280cb86b1c3
2018-11-14 22:13:27 -08:00
Yiding Jia 5b71408b89 Remove dynamic exception specification in RN MethodCall.h/cpp
Summary: Dynamic exception specifications are removed in C++17.

Reviewed By: mhorowitz

Differential Revision: D13078933

fbshipit-source-id: b1a1d7aed3f634c6bc699ab05a8c218bdddf5993
2018-11-14 21:16:29 -08:00
Rafael Oleza 06c13b3e06 Upgrade jest to v24.0.0-alpha.6
Summary: yayyay

Reviewed By: mjesun

Differential Revision: D13027838

fbshipit-source-id: ce51a82fa4c6dfa62e202e52c2733d161ae52883
2018-11-14 15:26:55 -08:00
Andrew Chen (Eng) b649fa96a0 Fix crash when removing root nodes
Summary: If a root node is being removed and has an id of NO_ID, it was likely already removed previously, likely due to a race condition caused by RN's async nature. In those cases, let's avoid crashing the app and instead silently ignore the root view removal.

Reviewed By: mdvacca

Differential Revision: D13055140

fbshipit-source-id: ec10f4c79f2ba21614f52f57557f6b3d734c9461
2018-11-14 10:57:02 -08:00
Chad Austin 56a416e3be nullptr -> folly::none in fbobjc/xplat
Summary:
In preparation for D12843022, starting using folly::none instead of
nullptr to indicate an empty optional.

Reviewed By: nlutsenko

Differential Revision: D13052075

fbshipit-source-id: ed869f98b5fb1556bca1e01e3ac3e44ea914dc52
2018-11-14 10:57:02 -08:00
Andrew Chen (Eng) 83405ff316 Fix crash when releasing RN views
Summary: There are cases where we're trying to drop a view that is not associated with a ViewManager. This is likely caused by race conditions that can occur if we're dropping a view from JS (when it's no longer used) but at the same time dropping it from native (when layout animation ends, when the rootview gets unmounted). In either of those cases, it should be safe to ignore the drop operation because the view was likely dropped already.

Reviewed By: mdvacca

Differential Revision: D13036643

fbshipit-source-id: 260ffb56d32a0d670ad08f449b8df165b2533195
2018-11-14 10:51:15 -08:00
Taras Tsugrii 9b781bdda8 Remove unused loads from xplat.
Summary:
Unused loads still take time to process and pollute
execution environment.

drop-conflicts

Reviewed By: passy

Differential Revision: D13054018

fbshipit-source-id: a8fe58d1c55c031925c2c0267e24e67f021cd91d
2018-11-14 10:51:15 -08:00
Kevin Gozali 39b8fa95a3 iOS TM: Rename RCTJSINativeModule => RCTTurboModule
Summary: Simple codemod to rename RCTJSINativeModule => RCTTurboModule (the protocol) for less confusion.

Reviewed By: PeteTheHeat

Differential Revision: D13054206

fbshipit-source-id: 4829dc69838c623336475ea8ee11be815d79711c
2018-11-14 10:42:04 -08:00
David Vacca e02a24b738 Dispatch events asynchronously
Summary: This diff fixes the dispaching of Async Events in Android C++ layer to ensure proper asynchronouns dispatching in the JS thread.

Reviewed By: shergin

Differential Revision: D12988348

fbshipit-source-id: 7aa60b11e2c264c2e68354ed83eb75139060d211
2018-11-14 09:45:26 -08:00
Sidharth Guglani 6eb5bd381c added functionality using which child node can tell parent node to use it as a reference baseline
Summary:
@public
Currently only parent can tell the layout to align its children based on baseline. But if one of the children is a column or row then basealign does not work as expected.

We have added an api setReferenceBaseline which when set to true would mean that it's baseline would be considered as the reference baseline for parent amongst its siblings. If there are more than one siblings with referenceBaseline set, the first one would be considered.

Reviewed By: davidaurelio

Differential Revision: D12883323

fbshipit-source-id: 19beccfc47d98bb38f81f5b66ba764e83680f821
2018-11-14 02:51:34 -08:00
Eric Butler a508134724 Fixed HTTP connection timeout on Android (#22164)
Summary:
Fixes #11666 (Which was incorrectly closed)
Pull Request resolved: https://github.com/facebook/react-native/pull/22164

Differential Revision: D13057001

Pulled By: hramos

fbshipit-source-id: bcd53e893bc7c114f866e54938166b74b8ae0299
2018-11-14 00:43:35 -08:00
Brent Vatne 04085337bc Fix regression in StyleSheet.setStyleAttributePreprocessor (#22262)
Summary:
This regression was caused by 199c918 - property values are initialized to true rather than a string that matches the property name now.
Pull Request resolved: https://github.com/facebook/react-native/pull/22262

Differential Revision: D13048839

Pulled By: hramos

fbshipit-source-id: 09471334c37f3930aae7e35066943f33f8e617e5
2018-11-13 23:38:01 -08:00
Ranjan Shrestha 2e465bca15 Android: Close websocket properly when remote server initiates close (#22248)
Summary:
When the remote server closes the websocket, the app doesn't get a 'close' event in Android, There is no issue on iOS.
Pull Request resolved: https://github.com/facebook/react-native/pull/22248

Differential Revision: D13047556

Pulled By: hramos

fbshipit-source-id: c5c56ea8418cfdf734fb51f863b3066856de6512
2018-11-13 23:19:42 -08:00
Kevin Gozali 339d9d3afb Guard Platform.isTesting under __DEV__
Summary: Testing is a __DEV__ time only, so let's optimize for prod bundles.

Reviewed By: ejanzer

Differential Revision: D13050583

fbshipit-source-id: a96e35e4d5f3bd09c235c11d4ece3e4d07882de7
2018-11-13 20:11:48 -08:00
Kevin Gozali d7a0c44590 iOS: add moduleForNameForcedLoad: to lookup modules by name and force load them
Summary:
Some module classes may not be loaded yet, so looking up via classes may not always give the correct instance. This diff added a new lookup method that delegate to the bridge delegate to force load the modules as needed.

The existing moduleForName: method was left untouched because it's solely used by RCTUIManager at the moment.

Reviewed By: dshahidehpour

Differential Revision: D13033876

fbshipit-source-id: 4082fcd68498004f678b4b95adc82b5b134fefdf
2018-11-13 20:11:47 -08:00
REDMOND\acoates 8826d8b233 Allow CxxModules to implement methods with two callbacks (#21586)
Summary:
When writing a native module in C++ using CxxModule, its not currently possible to write async methods which take two callbacks, that shouldn't be projected to JS as a promise.  I hit this when trying to implement the AppState module in c++.  AppState has a single method on it, getCurrentAppState, which takes two callbacks (a success and a failure callback).

This change adds a couple of new CxxModule::Method ctors, which allow devs to specify that they want two callbacks, but not a promise.  This is done using an extra tag in the ctor, similar to how you specify that you want to make a synchronous method.  I used the existing AsyncTag to indicate that the 2 callback version should be async, and not a promise.
Pull Request resolved: https://github.com/facebook/react-native/pull/21586

Reviewed By: shergin

Differential Revision: D10520204

Pulled By: fkgozali

fbshipit-source-id: bcb2dbd91cba3c1db987dc18960247218fdbc032
2018-11-13 19:52:40 -08:00
Héctor Ramos 11d4512abf Update React Native OSS Yarn and Gradle caches
Summary:
Update the yarn lockfile.
Add `metro/src/DeltaBundler/Serializers/plainJSBundle` definition to OSS Flow config.

Reviewed By: fkgozali, axe-fb

Differential Revision: D13046780

fbshipit-source-id: f7f68edacc6a4ed61c9e7b269e49148f915249cb
2018-11-13 18:57:26 -08:00
Rafael Oleza de60e8643a Bump metro@0.49.1
Summary: galavant-fistbump

Reviewed By: jeanlauliac

Differential Revision: D13027247

fbshipit-source-id: 3635527b6c745111b26d9f61666c30e696b04526
2018-11-12 11:31:28 -08:00
Mehdi Mulani eebc8e230a NetInfo: try to solve crash with releasing _firstTimeReachability
Summary:
@public
We're seeing a crash on line 191 when we do `CFRelease(self->_firstTimeReachability);`. My thinking is that there's a race condition between the deallocation coming from calling `getCurrentConnectivity` twice in a row and the callback coming back.

Reviewed By: PeteTheHeat

Differential Revision: D12982772

fbshipit-source-id: d3d882a074b67a5e547e7f480f561fcaf8d79ec4
2018-11-12 10:45:34 -08:00
Alexandre Kirszenberg c787866d64 Clearer HMR error messages
Summary:
GraphNotFoundError: When the user moves the app to the background on Android, restarts the Metro server and reopens the app, since the client hasn't requested either a delta or a bundle, the graph cache of the server is empty and thus we can't compute an update for the client (what if changes happened when the metro server was down?).

RevisionNotFoundError: I didn't manage to reproduce that one. It could happen if two clients live side-by-side, requesting the exact same bundle. In the future, if we want to handle that case, we'll need to manage a list of clients listening to a single graph so that we don't try to update the same graph multiple times for a single file change.

Disconnection: Same as GraphNotFoundError, but happens when the user moves the app to the background on iOS.

Reviewed By: mjesun

Differential Revision: D12960939

fbshipit-source-id: 5ac1dc7fd12bad5e0ee8dfa5a21c112773454ee5
2018-11-12 08:49:22 -08:00
Alexandre Kirszenberg bea57d871f DeltaPatcher: better support for the new Delta format
Summary: Adds support for the `deleted` key to remove modules from the bundle. Without this, source maps would break after removing a module, since it would still end up in the patched bundle but not in the source map.

Reviewed By: mjesun

Differential Revision: D12874011

fbshipit-source-id: 79239756854cb2c02f14ec8b0bb2b649766393fe
2018-11-12 08:41:06 -08:00
empyrical 0436bfce3e UITemplateProcessor: Fix case of include path (#22239)
Summary:
This pull request fixes a path name to be a proper case in `UITemplateProcessor`, which fixes this build warning:

```
{snip}/react/uimanager/UITemplateProcessor.cpp:17:10: warning: non-portable path to file '<react/core/ComponentDescriptor.h>';
      specified path differs in case from file name on disk [-Wnonportable-include-path]
         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         <react/core/ComponentDescriptor.h>
1 warning generated.
```
Pull Request resolved: https://github.com/facebook/react-native/pull/22239

Differential Revision: D13020871

Pulled By: shergin

fbshipit-source-id: 77555018cd569880518ff884ed8768effc4ea97e
2018-11-11 22:51:32 -08:00
David Vacca 33b966139e Avoid pre-allocating views for non-layoutable shadow nodes
Summary: This diff changes the behavior of the Scheduler.schedulerDidRequestPreliminaryViewAllocation to avoid pre-allocating views that are non-layoutables

Reviewed By: shergin

Differential Revision: D12962008

fbshipit-source-id: cb2670beafdcbd2116fbdaf2dc5d1b4726330ec2
2018-11-11 15:21:49 -08:00
Valentin Shergin 94d49e544d Fabric: Codemod: All `<fabric/...` includes were renamed to `<react/...`
Summary: We are moving to more stable APIs removing all mentiones of the effort name from the codebase.

Reviewed By: mdvacca

Differential Revision: D12912894

fbshipit-source-id: 4a0c6b9e7454b8b14e62d419e9e9311dc0c56e7a
2018-11-10 14:22:15 -08:00
Ram N 9f9390ddfc Moved androidID constant to a method
Summary:
androidID was a constant that was exposed as a Platform constant, but it seems to use slightly expensive methods when they need to be computed. Moving this to a method so that it is computed only when needed.
Test Plan

Reviewed By: ejanzer

Differential Revision: D6563853

fbshipit-source-id: 3c5929fcbc947c13c3a25f2bf473e145ac4bf73e
2018-11-10 08:54:18 -08:00
Peter Argany 188cbb04ad Reset module registry flag when resetting React Instance
Summary:
D12911108 fixed a UBN race condition by adding a flag for module registry.

This flag was never reset if react instance gets reset, causing an assert to fire in IG.

Reviewed By: fkgozali

Differential Revision: D13010651

fbshipit-source-id: e20453f3c546d759a58fd7fb93553f774410905f
2018-11-09 17:14:02 -08:00
Stepan Hruda 2bf0d54f15 Only include ServerHost constant in debug builds
Summary: I recently changed the implementation of `getServerHost` to be more expensive. I am excluding it from constants in non-debug builds, since loading that module lies on a critical path.

Reviewed By: axe-fb

Differential Revision: D12982150

fbshipit-source-id: eaaa50418726dbb2da2d517d0810f39b0dc7fac2
2018-11-09 17:03:02 -08:00
Andrew Chen (Eng) be282b5287 Fix ReactRootView attachRootView race condition
Summary:
Yet another issue with mAttachedRootViews. Every time attachRootView is called, the root view's id is reset to NO_ID. However, there can be a case where the react context has not initialized yet, so we delay attaching the root view to the instance manager until setupReactContext. If attachRootView was called a second time before the react context has finished initializing, we end up in a situation where we try to attach the same root view twice

I'm planning to remove mAttachedRootViews all together in a future diff, but for now let's avoid these crashes.

Reviewed By: mmmulani

Differential Revision: D12835167

fbshipit-source-id: ebef3fadc5f9f467eebb3b5644c685acc5ea10bf
2018-11-09 16:08:05 -08:00
Ram N d4aef08af9 Add a marker to indicate when JS thread priority is lowered
Summary:
When RN starts up, it lowers the default priority of the JS thread. This diff sets a point to see when the JS thread priority is lowered.

In subsequent diffs, we will be able to use this marker to play around with bumping the priority of the JS thread till TTI is done.

Reviewed By: alexeylang

Differential Revision: D8965457

fbshipit-source-id: 87cb1e3d3b370af183f388c411fd9a87a6cba250
2018-11-09 14:24:57 -08:00
Emily Janzer 1850906e5e Use nativeQPLTimestamp for InitializeCore marker point
Summary: It seems like `nativePerformanceNow` might not be getting installed in time to be used by InitializeCore on Android. Using PerformanceLogger.currentTimestamp instead, which uses nativeQPLTimestamp (which is what we should be using anyway)

Reviewed By: alexeylang

Differential Revision: D12875187

fbshipit-source-id: 6eda5d2ed7948ba48c63f76b40b2014511c32494
2018-11-09 14:14:40 -08:00
Andrew Chen (Eng) df7e8c64ff Fix ReactInstanceManager deadlock
Summary:
D12829677 introduced a deadlock where onHostResume holds the lock on `moveToResumedLifecycleState()` then waits for the `mReactContext` lock, but at the same time setupReactContext holds the `mReactContext` lock and waits for `moveToResumedLifecycleState()` https://our.intern.facebook.com/intern/everpaste/?handle=GAgXFgLQH1ZlQikBAMQzo2LZ6h9TbiAxAAAz. The purpose of the previous diff was to make sure that detachRootoView and
setupReactContext did not interfere with each other, and implemented that by blocking on mReactContext. Since this overloads the usage of mReactContext, let's use a different lock `mAttachedRootViews` to implement this behavior instead

Reviewed By: mdvacca

Differential Revision: D12989555

fbshipit-source-id: c12e5fd9c5fa4c2037167e9400dc0c1578e38959
2018-11-09 13:43:17 -08:00
Kevin Gozali 80f92adf1f iOS: ignore double registration of lazy modules with chrome attached
Summary: Depending on when Chrome debugger is attached, modules may get double registered. Simply ignore it for this case. The redbox was not a fatal error, which can be dismissed.

Reviewed By: shergin

Differential Revision: D12996107

fbshipit-source-id: 292f63102337077848842ca46b3daed08b1cae12
2018-11-09 11:39:06 -08:00
Mehdi Mulani d7865ebde8 Add another guard to lazilyLoadView
Summary:
it's possible that moduleForName won't return anything, so we should return.

Created from Diffusion's 'Open in Editor' feature.

Reviewed By: spredolac

Differential Revision: D12963342

fbshipit-source-id: c059595a68bfcaa38221e05fb62d70cc29887ca7
2018-11-09 11:25:13 -08:00
David Vacca fba7c1ece2 Add copyright header into ContextUtils class
Summary: Trivial diff to include copyright header into ContextUtils class

Reviewed By: achen1

Differential Revision: D13001556

fbshipit-source-id: 439f25647a094485381637ea2b59f62962b9c1ac
2018-11-09 11:21:26 -08:00