File tree Expand file tree Collapse file tree 6 files changed +24
-0
lines changed
Sophia Script for Windows 10 LTSC 2019/Module
Sophia Script for Windows 10 LTSC 2021/Module
Sophia Script for Windows 10 PowerShell 7/Module
Sophia Script for Windows 10/Module
Sophia Script for Windows 11 PowerShell 7/Module
Sophia Script for Windows 11/Module Expand file tree Collapse file tree 6 files changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -7375,6 +7375,10 @@ function CleanupTask
73757375 )
73767376 foreach ($VolumeCache in $VolumeCaches )
73777377 {
7378+ if (-not (Test-Path - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " ))
7379+ {
7380+ New-Item - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Force
7381+ }
73787382 New-ItemProperty - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Name StateFlags1337 - PropertyType DWord - Value 2 - Force
73797383 }
73807384
Original file line number Diff line number Diff line change @@ -8475,6 +8475,10 @@ function CleanupTask
84758475 )
84768476 foreach ($VolumeCache in $VolumeCaches )
84778477 {
8478+ if (-not (Test-Path - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " ))
8479+ {
8480+ New-Item - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Force
8481+ }
84788482 New-ItemProperty - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Name StateFlags1337 - PropertyType DWord - Value 2 - Force
84798483 }
84808484
Original file line number Diff line number Diff line change @@ -10729,6 +10729,10 @@ function CleanupTask
1072910729 )
1073010730 foreach ($VolumeCache in $VolumeCaches )
1073110731 {
10732+ if (-not (Test-Path - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " ))
10733+ {
10734+ New-Item - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Force
10735+ }
1073210736 New-ItemProperty - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Name StateFlags1337 - PropertyType DWord - Value 2 - Force
1073310737 }
1073410738
Original file line number Diff line number Diff line change @@ -10688,6 +10688,10 @@ function CleanupTask
1068810688 )
1068910689 foreach ($VolumeCache in $VolumeCaches )
1069010690 {
10691+ if (-not (Test-Path - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " ))
10692+ {
10693+ New-Item - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Force
10694+ }
1069110695 New-ItemProperty - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Name StateFlags1337 - PropertyType DWord - Value 2 - Force
1069210696 }
1069310697
Original file line number Diff line number Diff line change @@ -10192,6 +10192,10 @@ function CleanupTask
1019210192 )
1019310193 foreach ($VolumeCache in $VolumeCaches )
1019410194 {
10195+ if (-not (Test-Path - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " ))
10196+ {
10197+ New-Item - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Force
10198+ }
1019510199 New-ItemProperty - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Name StateFlags1337 - PropertyType DWord - Value 2 - Force
1019610200 }
1019710201
Original file line number Diff line number Diff line change @@ -10152,6 +10152,10 @@ function CleanupTask
1015210152 )
1015310153 foreach ($VolumeCache in $VolumeCaches )
1015410154 {
10155+ if (-not (Test-Path - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " ))
10156+ {
10157+ New-Item - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Force
10158+ }
1015510159 New-ItemProperty - Path " HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\VolumeCaches\$VolumeCache " - Name StateFlags1337 - PropertyType DWord - Value 2 - Force
1015610160 }
1015710161
You can’t perform that action at this time.
0 commit comments