Prevent double error message logging in case error in delete user
This commit is contained in:
parent
942bcff5c4
commit
3cf778b591
|
@ -1940,10 +1940,10 @@ def _delete_user(content):
|
||||||
log.info("User {} deleted".format(content.name))
|
log.info("User {} deleted".format(content.name))
|
||||||
return _("User '%(nick)s' deleted", nick=content.name)
|
return _("User '%(nick)s' deleted", nick=content.name)
|
||||||
else:
|
else:
|
||||||
log.warning(_("Can't delete Guest User"))
|
# log.warning(_("Can't delete Guest User"))
|
||||||
raise Exception(_("Can't delete Guest User"))
|
raise Exception(_("Can't delete Guest User"))
|
||||||
else:
|
else:
|
||||||
log.warning("No admin user remaining, can't delete user")
|
# log.warning("No admin user remaining, can't delete user")
|
||||||
raise Exception(_("No admin user remaining, can't delete user"))
|
raise Exception(_("No admin user remaining, can't delete user"))
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user