Skip to content

Commit

Permalink
Described types for argIf (#920)
Browse files Browse the repository at this point in the history
* Improve types for argIf command

* Bump package version

* Update changelog
  • Loading branch information
KonstantinTyukalov committed Feb 27, 2023
1 parent 7d04ce6 commit 149de35
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
6 changes: 5 additions & 1 deletion node/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,8 @@ Backported from ver.`3.4.0`:

## 4.2.0

- Added unhandledRejection event - [#912](https://github.com/microsoft/azure-pipelines-task-lib/pull/912)
- Added unhandledRejection event - [#912](https://github.com/microsoft/azure-pipelines-task-lib/pull/912)

## 4.3.0

- Described types for `argIf` - [#920](https://github.com/microsoft/azure-pipelines-task-lib/pull/920)
2 changes: 1 addition & 1 deletion node/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion node/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "azure-pipelines-task-lib",
"version": "4.2.0",
"version": "4.3.0",
"description": "Azure Pipelines Task SDK",
"main": "./task.js",
"typings": "./task.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion node/toolrunner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -853,7 +853,7 @@ export class ToolRunner extends events.EventEmitter {
* @param val string cmdline or array of strings
* @returns ToolRunner
*/
public argIf(condition: any, val: any) {
public argIf(condition: unknown, val: string | string[]): ToolRunner {
if (condition) {
this.arg(val);
}
Expand Down

0 comments on commit 149de35

Please sign in to comment.