Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions doc/100-General/10-Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ Released closed milestones can be found on [GitHub](https://github.com/Icinga/ic
* [#563](https://github.com/Icinga/icinga-powershell-framework/pull/563) Fixes checks like MSSQL using arguments of type `SecureString` not being usable with the Icinga for Windows REST-Api
* [#565](https://github.com/Icinga/icinga-powershell-framework/pull/565) Fixes internal cache file writer and reader to store changes inside a `.tmp` file first and validating the file state and content, before applying it to the actual file to prevent data corruption
* [#566](https://github.com/Icinga/icinga-powershell-framework/pull/566) Fixes useless testing and printing of error messages, in case the Icinga Agent is not installed during installation and Icinga for Windows printing plenty of errors, because the ACL checks cannot be completed because of the missing Agent
* [#568](https://github.com/Icinga/icinga-powershell-framework/pull/568) Fixes misleading SID error during uninstallation of Icinga for Windows or the Agent component

### Enhancements

Expand Down
5 changes: 4 additions & 1 deletion lib/core/windows/Uninstall-IcingaServiceUser.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ function Uninstall-IcingaServiceUser()
Set-IcingaUserPermissions -IcingaUser $IcingaUser -Remove;

$UserConfig = Remove-IcingaWindowsUser -IcingaUser $IcingaUser;
Update-IcingaWindowsUserPermission -SID $UserConfig.SID -Remove;

if ($null -ne $UserConfig -And ([string]::IsNullOrEmpty($UserConfig.SID) -eq $FALSE)) {
Update-IcingaWindowsUserPermission -SID $UserConfig.SID -Remove;
}

Restart-IcingaService 'icinga2';
Restart-IcingaWindowsService;
Expand Down