From f837bb3f2af1aa0df9faf9b8e489175fba41a1d2 Mon Sep 17 00:00:00 2001 From: Robert McLeod Date: Wed, 20 May 2020 14:54:32 +1000 Subject: [PATCH] Fixed payload for creating Organization Memberships --- azure-pipelines.yml | 4 ++-- functions/New-OrganizationMembership.ps1 | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 0bc5543..7138073 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -13,10 +13,10 @@ stages: steps: - checkout: self clean: true - - script: brew install gitversion + - script: dotnet tool install --global GitVersion.Tool --version 5.3.3 displayName: Install Gitversion - pwsh: | - $version = gitversion | ConvertFrom-Json | ForEach-Object MajorMinorPatch + $version = dotnet-gitversion | ConvertFrom-Json | ForEach-Object MajorMinorPatch Write-Host "##vso[build.updatebuildnumber]$version" displayName: Set Build Number - pwsh: | diff --git a/functions/New-OrganizationMembership.ps1 b/functions/New-OrganizationMembership.ps1 index 3e5f493..e2b7e9f 100644 --- a/functions/New-OrganizationMembership.ps1 +++ b/functions/New-OrganizationMembership.ps1 @@ -67,7 +67,7 @@ function New-OrganizationMembership { if ($PSCmdlet.ParameterSetName -eq 'Properties') { $path = '/api/v2/organization_memberships.json' $body = @{ - group_membership = @{ + organization_membership = @{ user_id = $UserId organization_id = $OrganizationId default = $Default @@ -76,7 +76,7 @@ function New-OrganizationMembership { } else { $path = '/api/v2/organization_memberships/create_many.json' $body = @{ - group_memberships = @($Membership) + organization_memberships = @($Membership) } }