Skip to content

Commit c85f907

Browse files
committed
Adding AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled
1 parent a4c63e0 commit c85f907

File tree

3 files changed

+24
-0
lines changed

3 files changed

+24
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
3030
- Added `Restore-PnPFlow` cmdlet which allows for undeleting a flow within 21 days of deletion. [#4415](https://github.com/pnp/powershell/pull/4415)
3131
- Added `-ExcludeDeprecated` to `Export-PnpTaxonomy` which allows for deprecated terms to be excluded from the export [#4053](https://github.com/pnp/powershell/pull/4053)
3232
- Added `-HidePeoplePreviewingFiles` to `Set-PnPSite` which allows for hiding the people previewing files feature on a site [#4416](https://github.com/pnp/powershell/pull/4416)
33+
- Added `-AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled` to `Set-PnPTenant` which allows for updating of web property bag when DenyAddAndCustomizePages is enabled
3334

3435
### Changed
3536

documentation/Set-PnPTenant.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ Set-PnPTenant [-SpecialCharactersStateInFileFolderNames <SpecialCharactersState>
160160
[-GuestSharingGroupAllowListInTenantByPrincipalIdentity <string[]>]
161161
[-OneDriveSharingCapability <SharingCapabilities>]
162162
[-DelayDenyAddAndCustomizePagesEnforcement <Boolean>]
163+
[-AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled <Boolean>]
163164
[-Force] [-Connection <PnPConnection>]
164165
```
165166

@@ -242,6 +243,20 @@ Accept pipeline input: False
242243
Accept wildcard characters: False
243244
```
244245
246+
### -AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled
247+
Enables or disables web property bag update when DenyAddAndCustomizePages is enabled. When AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled is set to $true, web property bag can be updated even if DenyAddAndCustomizePages is turned on when the user had AddAndCustomizePages (prior to DenyAddAndCustomizePages removing it).
248+
249+
```yaml
250+
Type: Boolean
251+
Parameter Sets: (All)
252+
253+
Required: False
254+
Position: Named
255+
Default value: None
256+
Accept pipeline input: False
257+
Accept wildcard characters: False
258+
```
259+
245260
### -ApplyAppEnforcedRestrictionsToAdHocRecipients
246261
When the feature is enabled, all guest users are subject to conditional access policy. By default guest users who are accessing SharePoint Online files with pass code are exempt from the conditional access policy.
247262

src/Commands/Admin/SetTenant.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -480,6 +480,9 @@ public class SetTenant : PnPAdminCmdlet
480480
[Parameter(Mandatory = false)]
481481
public string[] GuestSharingGroupAllowListInTenantByPrincipalIdentity { private set; get; }
482482

483+
[Parameter(Mandatory = false)]
484+
public bool? AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled { private set; get; }
485+
483486
protected override void ExecuteCmdlet()
484487
{
485488
AdminContext.Load(Tenant);
@@ -1539,6 +1542,11 @@ protected override void ExecuteCmdlet()
15391542
Tenant.ODBSharingCapability = OneDriveSharingCapability.Value;
15401543
modified = true;
15411544
}
1545+
if(AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled.HasValue)
1546+
{
1547+
Tenant.AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled = AllowWebPropertyBagUpdateWhenDenyAddAndCustomizePagesIsEnabled.Value;
1548+
modified = true;
1549+
}
15421550
if (GuestSharingGroupAllowListInTenantByPrincipalIdentity !=null)
15431551
{
15441552
if (GuestSharingGroupAllowListInTenantByPrincipalIdentity.Length > 0)

0 commit comments

Comments
 (0)