diff --git a/Remove-OldRevitLocals.ps1 b/Remove-OldRevitLocals.ps1 index 225d8a7..72bcbb4 100644 --- a/Remove-OldRevitLocals.ps1 +++ b/Remove-OldRevitLocals.ps1 @@ -4,8 +4,8 @@ $FileAllowedAge = (Get-Date).AddMonths(-1) # Build all Revit local paths $RevitLocalPaths = @() ForEach ( $userProfile in (Get-ChildItem -Path "${Env:SystemDrive}\Users" | Where-Object { $_.PSIsContainer }) ) { - If ( Test-Path "${userProfile}\Documents" ) { $RevitLocalPaths.Add("${userProfile}\Documents") } If ( Test-Path "${userProfile}\Documents\Revit Locals" ) { $RevitLocalPaths.Add("${userProfile}\Documents\Revit Locals") } + If ( Test-Path "${userProfile}\Documents" ) { $RevitLocalPaths.Add("${userProfile}\Documents") } } ForEach ( $path in $RevitLocalPaths ) {