File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -120,11 +120,10 @@ function Invoke-CIPPSharePointTemplateDeploy {
120120 Headers = $Headers
121121 APIName = $APIName
122122 }
123- # Team site vs Communication — select may persist {label,value}; default Team for
124- # older templates that omit sharePointTemplate.
125- $RawSharePointTemplate = [string ]($SiteTemplate.sharePointTemplate.value ?? $SiteTemplate.sharePointTemplate )
126- $SiteParams.TemplateName = if ($RawSharePointTemplate -in @ (' Team' , ' Communication' )) {
127- $RawSharePointTemplate
123+ # Team site vs Communication — createAs may persist {label,value}; default Team.
124+ $RawCreateAs = [string ]($SiteTemplate.createAs.value ?? $SiteTemplate.createAs )
125+ $SiteParams.TemplateName = if ($RawCreateAs -in @ (' Team' , ' Communication' )) {
126+ $RawCreateAs
128127 } else {
129128 ' Team'
130129 }
You can’t perform that action at this time.
0 commit comments