Fix codestyle for typeof comparison (#19928)
Eugene Maslovich committed
Oct 1, 2020 at 18:26 UTC
43363e2795393a00fd77312a16d6b80e626c29de
1 file changed
+3
-3
packages/react-reconciler/src/ReactFiberHooks.new.js
+3
-3
@@ -1248,7 +1248,7 @@ function mountEffect(
1248
): void {
1249
if (__DEV__) {
1250
// $FlowExpectedError - jest isn't a global, and isn't recognized outside of tests
1251
- if ('undefined' !== typeof jest) {
1251
+ if (typeof jest !== 'undefined') {
1252
warnIfNotCurrentlyActingEffectsInDEV(currentlyRenderingFiber);
1253
}
1254
}
@@ -1276,7 +1276,7 @@ function updateEffect(
1276
): void {
1277
if (__DEV__) {
1278
// $FlowExpectedError - jest isn't a global, and isn't recognized outside of tests
1279
- if ('undefined' !== typeof jest) {
1279
+ if (typeof jest !== 'undefined') {
1280
warnIfNotCurrentlyActingEffectsInDEV(currentlyRenderingFiber);
1281
}
1282
}
@@ -1771,7 +1771,7 @@ function dispatchAction<S, A>(
1771
}
1772
if (__DEV__) {
1773
// $FlowExpectedError - jest isn't a global, and isn't recognized outside of tests
1774
- if ('undefined' !== typeof jest) {
1774
+ if (typeof jest !== 'undefined') {
1775
warnIfNotScopedWithMatchingAct(fiber);
1776
warnIfNotCurrentlyActingUpdatesInDev(fiber);
1777
}