PSDevOps icon indicating copy to clipboard operation
PSDevOps copied to clipboard

Piping repo object to Get-/Set-ADOPermission sets the wrong value

Open stefanes opened this issue 3 years ago • 0 comments

Piping a repo object to Get-/Set-ADOPermission sets the RepositoryID parameter to the repo name instead of the repo ID.

Workaround:

$repo = Get-ADOProject -PAT $Token -Organization $Organization -Project $ProjectName | Get-ADORepository -RepositoryID $RepoName
$repo | Get-ADOPermission -RepositoryID { $_.id } -ExpandACL

stefanes avatar Dec 16 '21 17:12 stefanes