Skip to content

Commit 97ce47f

Browse files
committed
fix(Expo): use correct string to identify MainApplication.kt in SDK 55
1 parent d28f212 commit 97ce47f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

expo/plugin/withCodePushAndroid.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const { withMainApplication, WarningAggregator } = require('expo/config-plugins');
22

33
const IMPORT_CODE_PUSH = 'import com.microsoft.codepush.react.CodePush';
4-
const RN_082_MARKER = ' getDefaultReactHost(';
4+
const RN_082_MARKER = 'ExpoReactHostFactory.getDefaultReactHost(';
55
const JS_BUNDLE_FILE_PATH_ARGUMENT = 'jsBundleFilePath = CodePush.getJSBundleFile()';
66

77
function androidMainApplicationApplyImplementation(mainApplication, find, add, reverse = false) {
@@ -32,7 +32,7 @@ function addJsBundleFilePathArgument(mainApplication) {
3232
return mainApplication;
3333
}
3434

35-
const packageListArgumentPattern = /(packageList\s*=\s*\n\s*PackageList\(this\)[\s\S]+?\},\s*\n)/;
35+
const packageListArgumentPattern = /(packageList\s*=\s*\n\s*PackageList\(this\)[\s\S]+?\},?\s*\n)/;
3636

3737
if (!packageListArgumentPattern.test(mainApplication)) {
3838
WarningAggregator.addWarningAndroid(

0 commit comments

Comments
 (0)