diff --git a/src/applications/conpherence/controller/ConpherenceUpdateController.php b/src/applications/conpherence/controller/ConpherenceUpdateController.php --- a/src/applications/conpherence/controller/ConpherenceUpdateController.php +++ b/src/applications/conpherence/controller/ConpherenceUpdateController.php @@ -16,9 +16,13 @@ switch ($action) { case ConpherenceUpdateActions::REMOVE_PERSON: $person_phid = $request->getStr('remove_person'); - if ($person_phid != $user->getPHID()) { + // This condition and one below enforces the remove_person to be + // same as the acting_person. + // By default all we need is to check whether the acting_person + // can edit the room or not. + // if ($person_phid != $user->getPHID()) { $needed_capabilities[] = PhabricatorPolicyCapability::CAN_EDIT; - } + // } break; case ConpherenceUpdateActions::ADD_PERSON: case ConpherenceUpdateActions::METADATA: @@ -111,7 +115,10 @@ break; } $person_phid = $request->getStr('remove_person'); - if ($person_phid && $person_phid == $user->getPHID()) { + // Even though we are no longer checking for the user to be himself, + // it is still necessary for the phid of the user to be specified + if ($person_phid) { + // if ($person_phid && $person_phid == $user->getPHID()) { $xactions[] = id(new ConpherenceTransaction()) ->setTransactionType( ConpherenceTransaction::TYPE_PARTICIPANTS) diff --git a/src/applications/conpherence/view/ConpherencePeopleWidgetView.php b/src/applications/conpherence/view/ConpherencePeopleWidgetView.php --- a/src/applications/conpherence/view/ConpherencePeopleWidgetView.php +++ b/src/applications/conpherence/view/ConpherencePeopleWidgetView.php @@ -21,7 +21,10 @@ foreach ($handles as $handle) { $user_phid = $handle->getPHID(); $remove_html = ''; - if ($user_phid == $user->getPHID()) { + // Add the 'remove' icon next to all users. + // The actual validation will be handled in ConpherenceUpdateController + // instead. + // if ($user_phid == $user->getPHID()) { $icon = id(new PHUIIconView()) ->setIcon('fa-times lightbluetext'); $remove_html = javelin_tag( @@ -35,7 +38,7 @@ ), ), $icon); - } + // } $body[] = phutil_tag( 'div', array(