mirror of https://github.com/status-im/metro.git
Tiny refactor; use `== null`
Reviewed By: davidaurelio Differential Revision: D7575286 fbshipit-source-id: a9e0fc7ee5a15ce1eabb84759cf584df2acca008
This commit is contained in:
parent
11cc6a7f65
commit
8073bdaa08
|
@ -49,7 +49,7 @@ const babelOptions = {
|
|||
};
|
||||
|
||||
function normalize({code}): string {
|
||||
if (code === undefined || code === null) {
|
||||
if (code == null) {
|
||||
return 'FAIL';
|
||||
}
|
||||
return transformSync(code, babelOptions).code;
|
||||
|
|
|
@ -219,7 +219,7 @@ function getPreset7() {
|
|||
['transform-modules-commonjs', {strict: false, allowTopLevelThis: true}],
|
||||
);
|
||||
|
||||
if (src !== null && src !== undefined) {
|
||||
if (src != null) {
|
||||
addPluginsWhenSourceNeedsIt(src, plugins);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue