We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b6d2c7f + dd81668 commit 645a10cCopy full SHA for 645a10c
src/scripts/android/updateAndroidManifest.js
@@ -41,6 +41,7 @@
41
function getManifest(context) {
42
let pathToManifest;
43
let manifest;
44
+ let targetSdk;
45
46
try {
47
// cordova platform add [email protected]
@@ -71,8 +72,8 @@
71
72
const mainActivityIndex = getMainLaunchActivityIndex(
73
manifest.manifest.application[0].activity
74
);
- const targetSdk =
75
- manifest.manifest["uses-sdk"][0].$["android:targetSdkVersion"];
+ const usesSdk = manifest.manifest["uses-sdk"];
76
+ targetSdk = Array.isArray(usesSdk) ? usesSdk[0].$["android:targetSdkVersion"] : undefined;
77
78
return {
79
file: manifest,
0 commit comments