Skip to content

Commit

Permalink
Small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
farag2 committed Jul 28, 2024
1 parent a6e0064 commit 1623f07
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 17 deletions.
6 changes: 3 additions & 3 deletions src/Sophia_Script_for_Windows_10/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -1388,7 +1388,7 @@ function ErrorReporting
{
if ((Get-WindowsEdition -Online).Edition -notmatch "Core")
{
Get-ScheduledTask -TaskName QueueReporting | Disable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Disable-ScheduledTask
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -PropertyType DWord -Value 1 -Force
}

Expand All @@ -1397,7 +1397,7 @@ function ErrorReporting
}
"Enable"
{
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down Expand Up @@ -8083,7 +8083,7 @@ function RecommendedTroubleshooting
Set-Policy -Scope Computer -Path SOFTWARE\Policies\Microsoft\Windows\DataCollection -Name AllowTelemetry -Type DWORD -Value 3

# Turn on Windows Error Reporting
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down
4 changes: 2 additions & 2 deletions src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -1345,7 +1345,7 @@ function ErrorReporting
{
if ((Get-WindowsEdition -Online).Edition -notmatch "Core")
{
Get-ScheduledTask -TaskName QueueReporting | Disable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Disable-ScheduledTask
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -PropertyType DWord -Value 1 -Force
}

Expand All @@ -1354,7 +1354,7 @@ function ErrorReporting
}
"Enable"
{
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down
6 changes: 3 additions & 3 deletions src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -1345,7 +1345,7 @@ function ErrorReporting
{
if ((Get-WindowsEdition -Online).Edition -notmatch "Core")
{
Get-ScheduledTask -TaskName QueueReporting | Disable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Disable-ScheduledTask
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -PropertyType DWord -Value 1 -Force
}

Expand All @@ -1354,7 +1354,7 @@ function ErrorReporting
}
"Enable"
{
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down Expand Up @@ -7068,7 +7068,7 @@ function RecommendedTroubleshooting
Set-Policy -Scope Computer -Path SOFTWARE\Policies\Microsoft\Windows\DataCollection -Name AllowTelemetry -Type DWORD -Value 3

# Turn on Windows Error Reporting
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1392,7 +1392,7 @@ function ErrorReporting
{
if ((Get-WindowsEdition -Online).Edition -notmatch "Core")
{
Get-ScheduledTask -TaskName QueueReporting | Disable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Disable-ScheduledTask
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -PropertyType DWord -Value 1 -Force
}

Expand All @@ -1401,7 +1401,7 @@ function ErrorReporting
}
"Enable"
{
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down Expand Up @@ -8089,7 +8089,7 @@ function RecommendedTroubleshooting
Set-Policy -Scope Computer -Path SOFTWARE\Policies\Microsoft\Windows\DataCollection -Name AllowTelemetry -Type DWORD -Value 3

# Turn on Windows Error Reporting
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down
6 changes: 3 additions & 3 deletions src/Sophia_Script_for_Windows_11/Module/Sophia.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -1362,7 +1362,7 @@ function ErrorReporting
{
if ((Get-WindowsEdition -Online).Edition -notmatch "Core")
{
Get-ScheduledTask -TaskName QueueReporting | Disable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Disable-ScheduledTask
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -PropertyType DWord -Value 1 -Force
}

Expand All @@ -1371,7 +1371,7 @@ function ErrorReporting
}
"Enable"
{
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down Expand Up @@ -7874,7 +7874,7 @@ function RecommendedTroubleshooting
Set-Policy -Scope Computer -Path SOFTWARE\Policies\Microsoft\Windows\DataCollection -Name AllowTelemetry -Type DWORD -Value 3

# Turn on Windows Error Reporting
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1380,7 +1380,7 @@ function ErrorReporting
{
if ((Get-WindowsEdition -Online).Edition -notmatch "Core")
{
Get-ScheduledTask -TaskName QueueReporting | Disable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Disable-ScheduledTask
New-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -PropertyType DWord -Value 1 -Force
}

Expand All @@ -1389,7 +1389,7 @@ function ErrorReporting
}
"Enable"
{
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down Expand Up @@ -7894,7 +7894,7 @@ function RecommendedTroubleshooting
Set-Policy -Scope Computer -Path SOFTWARE\Policies\Microsoft\Windows\DataCollection -Name AllowTelemetry -Type DWORD -Value 3

# Turn on Windows Error Reporting
Get-ScheduledTask -TaskName QueueReporting | Enable-ScheduledTask
Get-ScheduledTask -TaskName QueueReporting -ErrorAction Ignore | Enable-ScheduledTask
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\Windows Error Reporting" -Name Disabled -Force -ErrorAction Ignore

Get-Service -Name WerSvc | Set-Service -StartupType Manual
Expand Down

0 comments on commit 1623f07

Please sign in to comment.