Quick ci fix (#3084)
The defensive flattening of the inputs was at the wrong place. --- #### Does this PR need a docs update or release note? - [ ] ✅ Yes, it's included - [ ] 🕐 Yes, but in a later PR - [ ] ⛔ No #### Type of change <!--- Please check the type of change your PR introduces: ---> - [ ] 🌻 Feature - [x] 🐛 Bugfix - [ ] 🗺️ Documentation - [ ] 🤖 Supportability/Tests - [x] 💻 CI/Deployment - [ ] 🧹 Tech Debt/Cleanup #### Issue(s) <!-- Can reference multiple issues. Use one of the following "magic words" - "closes, fixes" to auto-close the Github issue. --> * #<issue> #### Test Plan <!-- How will this be tested prior to merging.--> - [x] 💪 Manual - [ ] ⚡ Unit test - [ ] 💚 E2E
This commit is contained in:
parent
f2fecb91b6
commit
de3554d869
@ -112,10 +112,6 @@ function Purge-Library {
|
||||
|
||||
######## MAIN #########
|
||||
|
||||
# ensure that there are no unexpanded entries in the list of parameters
|
||||
$LibraryNameList = $LibraryNameList | ForEach-Object { @($_.Split(',').Trim()) }
|
||||
$FolderPrefixPurgeList = $FolderPrefixPurgeList | ForEach-Object { @($_.Split(',').Trim()) }
|
||||
|
||||
# Setup SharePointPnP
|
||||
if (-not (Get-Module -ListAvailable -Name PnP.PowerShell)) {
|
||||
$ProgressPreference = 'SilentlyContinue'
|
||||
@ -173,6 +169,10 @@ Write-Host "`nAuthenticating and connecting to $SiteUrl"
|
||||
Connect-PnPOnline -Url $siteUrl -Credential $cred
|
||||
Write-Host "Connected to $siteUrl`n"
|
||||
|
||||
# ensure that there are no unexpanded entries in the list of parameters
|
||||
$LibraryNameList = $LibraryNameList | ForEach-Object { @($_.Split(',').Trim()) }
|
||||
$FolderPrefixPurgeList = $FolderPrefixPurgeList | ForEach-Object { @($_.Split(',').Trim()) }
|
||||
|
||||
foreach ($library in $LibraryNameList) {
|
||||
Purge-Library -LibraryName $library -PurgeBeforeTimestamp $PurgeBeforeTimestamp -FolderPrefixPurgeList $FolderPrefixPurgeList -SiteSuffix $siteSiffix
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user