Skip to content

Commit 1301dde

Browse files
authored
fix: Change made to handle if mode in command argument includes build flavor as well, i.e. productionDebug. #2323 (#2324)
1 parent 8492fde commit 1301dde

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

packages/cli-platform-android/src/commands/runAndroid/tryInstallAppOnDevice.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ function tryInstallAppOnDevice(
1616
// "app" is usually the default value for Android apps with only 1 app
1717
const {appName, sourceDir} = androidProject;
1818

19-
const defaultVariant = (args.mode || 'debug').toLowerCase();
19+
const defaultVariant = 'debug';
2020

21-
// handle if selected task from interactive mode includes build flavour as well, eg. installProductionDebug should create ['production','debug'] array
22-
const variantFromSelectedTask = selectedTask
21+
// handle if selected task from interactive mode, or mode from arguments, includes build flavour as well, eg. installProductionDebug should create ['production','debug'] array
22+
const variantFromSelectedTask = (selectedTask ?? args.mode)
2323
?.replace('install', '')
2424
.split(/(?=[A-Z])/);
2525

0 commit comments

Comments
 (0)