Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SPOSharingSettings: Multiple sites returned from Get-PnPTenantSite #4328

Merged
merged 1 commit into from
Feb 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@
* Fix typo in variable which made it export incorrectly and report that
resource was not in correct state due to testing an incorrect value
FIXES [#3972](https://github.com/microsoft/Microsoft365DSC/issues/3972)
* SPOSharingSettings
* Fixed an issue where the resource would return multiple sites.
FIXES [#2759](https://github.com/microsoft/Microsoft365DSC/issues/2759)
* DEPENDENCIES
* Updated DSCParser to version 1.4.0.2.
* Updated Microsoft.Graph dependencies to version 2.13.1.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -520,7 +520,7 @@ function Set-TargetResource
Set-PnPTenant @CurrentParameters | Out-Null
if ($SetMySharingCapability)
{
$mysite = Get-PnPTenantSite | Where-Object { $_.Url -match '-my.sharepoint.com/' }
$mysite = Get-PnPTenantSite | Where-Object { $_.Url -match '-my.sharepoint.com/' -and $_.Template -notmatch '^RedirectSite#' }
Set-PnPTenantSite -Identity $mysite.Url -SharingCapability $MySiteSharingCapability
}
}
Expand Down
Loading