From fc7f4e880ddfed812438fabc791c5f5056f541e6 Mon Sep 17 00:00:00 2001 From: cash Date: Wed, 17 Nov 2010 12:38:14 +0000 Subject: Closes #1422 admin user actions now check for self before banning, deleting, or removing admin privileges git-svn-id: http://code.elgg.org/elgg/trunk@7332 36083f99-b078-4883-b0ff-0f9b5a30f544 --- actions/admin/user/unban.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'actions/admin/user/unban.php') diff --git a/actions/admin/user/unban.php b/actions/admin/user/unban.php index 66173623a..883e074ed 100644 --- a/actions/admin/user/unban.php +++ b/actions/admin/user/unban.php @@ -12,10 +12,10 @@ $access_status = access_get_show_hidden_status(); access_show_hidden_entities(true); $guid = get_input('guid'); -$obj = get_entity($guid); +$user = get_entity($guid); -if (($obj instanceof ElggUser) && ($obj->canEdit())) { - if ($obj->unban()) { +if (($user instanceof ElggUser) && ($user->canEdit())) { + if ($user->unban()) { system_message(elgg_echo('admin:user:unban:yes')); } else { register_error(elgg_echo('admin:user:unban:no')); -- cgit v1.2.3