iif implementation doesn't support 1 or 2 parameter#14234
iif implementation doesn't support 1 or 2 parameter#14234ChristopherHX wants to merge 1 commit intoMicrosoftDocs:mainfrom
Conversation
Adjust docs to match implementation
```
steps:
- ${{ if iif(False, False) }}:
- bash: ok
```
is a syntax error for the validate pipeline feature
|
@ChristopherHX : Thanks for your contribution! The author(s) have been notified to review your proposed change. |
|
Can you review the proposed changes? Important: When the changes are ready for publication, adding a #label:"aq-pr-triaged" |
|
@juliakm - Could you review this proposed update to your article and enter Thanks! |
|
#reassign:ramiMSFT |
|
@ChristopherHX : Thanks for your contribution! The author(s) and reviewer(s) have been notified to review your proposed change. |
|
#assign-reviewer:ramiMSFT |
|
@ramiMSFT Can you review this old PR and determine whether it needs to be closed or merged? IMPORTANT: When the changes are ready for publication, add a @MicrosoftDocs/public-repo-pr-review-team |
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Updates the Azure Pipelines expression documentation to reflect the actual iif function signature (3 parameters required), preventing users from assuming 1–2 parameters are valid.
Changes:
- Corrected the documented minimum parameter count for
iiffrom 1 to 3.
| ### iif | ||
| * Returns the second parameter if the first parameter evaluates to `True`, and the third parameter otherwise | ||
| * Min parameters: 1. Max parameters: 3 | ||
| * Min parameters: 3. Max parameters: 3 |
There was a problem hiding this comment.
The doc currently states the arity as separate min/max bullets, but doesn't explicitly say that iif requires exactly three arguments (condition, trueValue, falseValue). Consider rewording to make the restriction unambiguous (e.g., 'Exactly 3 parameters') to reduce future confusion and avoid readers interpreting this as a general min/max guideline rather than a strict requirement.
| * Min parameters: 3. Max parameters: 3 | |
| * Exactly 3 parameters: condition, trueValue, falseValue |
Adjust docs to match implementation assuming this is not autogenerated
is a syntax error for the validate pipeline feature
After I saw the documentation, I thought that 1 or 2 parameters are valid as well and no it didn't work