Fix create-pull-request bug (#842)

Co-authored-by: Chidozie Ononiwu <chononiw@microsoft.com>
This commit is contained in:
Azure SDK Bot 2020-10-22 15:28:26 -07:00 committed by GitHub
parent 2f10cdf30b
commit d904267489
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 5 deletions

View File

@ -86,4 +86,4 @@ steps:
-UserReviewers "${{ parameters.GHReviewersVariable }}"
-TeamReviewers "${{ parameters.GHTeamReviewersVariable }}"
-Assignees "${{ parameters.GHAssignessVariable }}"
-CloseAfterOpenForTesting $${{ parameters.CloseAfterOpenForTesting }}
-CloseAfterOpenForTesting $${{ coalesce(parameters.CloseAfterOpenForTesting, 'false') }}

View File

@ -18,6 +18,7 @@ parameters:
GHReviewersVariable: ''
GHTeamReviewersVariable: '' # externally set, as eng-common does not have the identity-resolver. Run as pre-step
OnboardingBranch: ''
CloseAfterOpenForTesting: false
steps:
- pwsh: |
@ -83,7 +84,7 @@ steps:
GHReviewersVariable: ${{ parameters.GHReviewersVariable }}
GHTeamReviewersVariable: ${{ parameters.GHTeamReviewersVariable }}
PRLabels: ${{ parameters.PRLabels }}
CloseAfterOpenForTesting: $(TestPipeline)
CloseAfterOpenForTesting: ${{ parameters.CloseAfterOpenForTesting }}
- ${{if ne( parameters['OnboardingBranch'], '')}}:
- pwsh: |
@ -124,4 +125,4 @@ steps:
ScriptDirectory: ${{ parameters.WorkingDirectory }}/${{ parameters.ScriptDirectory }}
GHReviewersVariable: ${{ parameters.GHReviewersVariable }}
GHTeamReviewersVariable: ${{ parameters.GHTeamReviewersVariable }}
CloseAfterOpenForTesting: $(TestPipeline)
CloseAfterOpenForTesting: ${{ parameters.CloseAfterOpenForTesting }}

View File

@ -35,7 +35,7 @@ function Invoke-GitHubAPIPost {
else {
$warning = "{0} with Uri [ $apiURI ] did not fire request because of empty body." -f (Get-PSCallStack)[1].FunctionName
LogWarning $warning
exit 0
return $null
}
}
catch {
@ -69,7 +69,7 @@ function Invoke-GitHubAPIPatch {
else {
$warning = "{0} with Uri [ $apiURI ] did not fire request because of empty body." -f (Get-PSCallStack)[1].FunctionName
LogWarning $warning
exit 0
return $null
}
}
catch {