Azure / Azure/azure-powershell
[Doc]: Update-AzGallery -Tenant has incorrect documentation
- Dominant language
- C#
- Stars
- 4.8k
- Forks
- 4.3k
- Avg merge
- 2d 17h
- Merged PRs (30d)
- 51
Description
### Type of issue
Code doesn't work
### Feedback
https://learn.microsoft.com/en-us/powershell/module/az.compute/update-azgallery?view=azps-15.4.0
this example shows
Update-AzGallery -ResourceGroupName $rgname -Name $galleryName -Permission Groups -Share -Tenant xxxxxxxx-xxx-xxxxxxx,zzzzzz-zzzzzzz-zzzzzz
that tenantIds should be comma separated values, but it doesn't work like it shows
I have got it to work by passing a string[]
for example
```powerShell
$tenantIds = @( 'xxxxxxxx-xxx-xxxxxxx'; 'zzzzzz-zzzzzzz-zzzzzz')
Update-AzGallery -ResourceGroupName $rgname -Name $galleryName -Permission Groups -Share -Tenant $tenantIds
```
works, but
```powerShell
$tenantIds = @( 'xxxxxxxx-xxx-xxxxxxx'; 'zzzzzz-zzzzzzz-zzzzzz')
Update-AzGallery -ResourceGroupName $rgname -Name $galleryName -Permission Groups -Share -Tenant $($tenantIds -join ',')
```
doesn't work
### Page URL
https://learn.microsoft.com/en-us/powershell/module/az.compute/update-azgallery?view=azps-15.4.0
### Content source URL
_No response_
### Author
_No response_
### Document Id
_No response_
### Platform Id
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.