Skip to content

Commit

Permalink
V4.1.16
Browse files Browse the repository at this point in the history
  • Loading branch information
UrielCh committed Nov 8, 2022
1 parent d1ae9d9 commit f4831d9
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# CHANGELOG

## V4.1.16 (2022-11-08)
* add `args` in interface StartServiceOptions can be a `string` or a `string[]`

## V4.1.15 (2022-11-08)
* add `args: string[]` in interface StartServiceOptions

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@u4/adbkit",
"version": "4.1.15",
"version": "4.1.16",
"description": "A Typescript client for the Android Debug Bridge.",
"keywords": [
"adb",
Expand Down
7 changes: 5 additions & 2 deletions src/adb/command/host-transport/startactivity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,11 @@ export default class StartActivityCommand extends Command<boolean> {
args.push('-f', this.escape(options.flags));
}
if (options.args) {
for (const arg of options.args)
args.push(this.escape(arg));
if (typeof options.args === 'string')
args.push(this.escape(args));
else
for (const arg of options.args)
args.push(this.escape(arg));
}
return args;
}
Expand Down
2 changes: 1 addition & 1 deletion src/models/StartServiceOptions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,5 @@ export default interface StartServiceOptions {
/**
* args to append at the end
*/
args?: string[];
args?: string | string[];
}

0 comments on commit f4831d9

Please sign in to comment.