mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-07-25 22:16:08 +00:00
General fixes
+Fixed a bug that permitted to edit alliance leader's permissions
This commit is contained in:
@@ -452,8 +452,9 @@ class Alliance {
|
||||
}
|
||||
|
||||
if($this->userPermArray['opt1'] == 0) $form->addError("perm", NO_PERMISSION);
|
||||
elseif($database->getUserField($post['a_user'], "alliance", 0) != $session->alliance) $form->addError("perm", USER_NOT_IN_YOUR_ALLY);
|
||||
elseif($database->getUserField($post['a_user'], "alliance", 0) != $session->alliance) $form->addError("perm", USER_NOT_IN_YOUR_ALLY);
|
||||
elseif($post['a_user'] == $session->uid) $form->addError("perm", CANT_EDIT_YOUR_PERMISSIONS);
|
||||
elseif($database->isAllianceOwner($_POST['a_user'])) $form->addError("perm", CANT_EDIT_LEADER_PERMISSIONS);
|
||||
else
|
||||
{
|
||||
$database->updateAlliPermissions($post['a_user'], $session->alliance, $post['a_titel'], $post['e1'], $post['e2'], $post['e3'], $post['e4'], $post['e5'], $post['e6'], $post['e7']);
|
||||
|
||||
Reference in New Issue
Block a user