2
0
Эх сурвалжийг харах

Added CheckService Functioin to start dmwappushservice if stopped

Added a function with an If statement that checks if the service dmwappushservice is running and if not then it will start it.
Richard Newton 6 жил өмнө
parent
commit
9d3e8b8504

+ 7 - 0
Windows10SysPrepDebloater.ps1

@@ -201,6 +201,13 @@ Function FixWhitelistedApps {
     Get-AppxPackage -allusers Microsoft.Windows.Photos | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "$($_.InstallLocation)\AppXManifest.xml"} }
 }
 
+Function CheckService {
+
+  Param([switch]$Debloat)
+  
+  If (Get-Service -Name dmwappushservice | Where-Object {$_.Status -eq "Stopped"}) {
+        Start-Service -Name dmwappushservice }
+
 Write-Output "Initiating Sysprep"
 Begin-SysPrep
 Write-Output "Removing bloatware apps."