Correct a parameter order swap in "diffusion.historyquery" for Mercurial
[phabricator.git] / src / applications / conpherence / controller / ConpherenceParticipantController.php
bloba82439f311281d743ca8d05c920220fc349fe250
1 <?php
3 final class ConpherenceParticipantController extends ConpherenceController {
5 public function shouldAllowPublic() {
6 return true;
9 public function handleRequest(AphrontRequest $request) {
10 $viewer = $request->getViewer();
12 $conpherence_id = $request->getURIData('id');
13 if (!$conpherence_id) {
14 return new Aphront404Response();
17 $conpherence = id(new ConpherenceThreadQuery())
18 ->setViewer($viewer)
19 ->withIDs(array($conpherence_id))
20 ->needParticipants(true)
21 ->executeOne();
23 if (!$conpherence) {
24 return new Aphront404Response();
27 $uri = $this->getApplicationURI('update/'.$conpherence->getID().'/');
28 $content = id(new ConpherenceParticipantView())
29 ->setUser($this->getViewer())
30 ->setConpherence($conpherence)
31 ->setUpdateURI($uri);
33 $content = array('widgets' => $content);
35 return id(new AphrontAjaxResponse())->setContent($content);