Module: check_mk
Branch: master
Commit: e714531a142474201f35f81c7dedfedea38134ce
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=e714531a142474…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Feb 4 14:35:45 2013 +0100
WATO: small improvement to error handling
---
web/htdocs/wato.py | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 420c978..f8dd222 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -7751,6 +7751,9 @@ def mode_users(phase):
if delid == config.user_id:
raise MKUserError(None, _("You cannot delete your own account!"))
+ if delid not in users:
+ return None # The account does not exist (anymore), no deletion needed
+
c = wato_confirm(_("Confirm deletion of user %s" % delid),
_("Do you really want to delete the user %s?" %
delid))
if c: