Skip to content
Snippets Groups Projects
Commit c9a8f912 authored by Michael Klier's avatar Michael Klier
Browse files

FS#1137 don't allow admin user to delete himself

darcs-hash:20081011133640-23886-b2bc0d25ccc41af3c4c9d1c387eef3efea16689a.gz
parent 70a7f6ba
No related branches found
No related tags found
No related merge requests found
......@@ -393,6 +393,11 @@ class admin_plugin_usermanager extends DokuWiki_Admin_Plugin {
if (!is_array($selected) || empty($selected)) return false;
$selected = array_keys($selected);
if(in_array($_SERVER['REMOTE_USER'], $selected)) {
msg("You can't delete yourself!", -1);
return false;
}
$count = $this->_auth->triggerUserMod('delete', array($selected));
if ($count == count($selected)) {
$text = str_replace('%d', $count, $this->lang['delete_ok']);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment