Skip to content

Commit 9164a37

Browse files
authored
fix: add check to api param to prevent crash (LonelyCpp#212)
1 parent 584798d commit 9164a37

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

Diff for: babel.config.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
module.exports = function (api) {
2-
api.cache(false);
2+
if (api) {
3+
api.cache(false);
4+
}
5+
36
return {
47
presets: ['module:metro-react-native-babel-preset'],
58
};

0 commit comments

Comments
 (0)