Differential D12017 Diff 28942 src/applications/diffusion/controller/DiffusionInlineCommentController.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/diffusion/controller/DiffusionInlineCommentController.php
| Show All 37 Lines | return id(new PhabricatorAuditInlineComment()) | ||||
| ->setCommitPHID($commit_phid) | ->setCommitPHID($commit_phid) | ||||
| ->setPathID($path_id); | ->setPathID($path_id); | ||||
| } | } | ||||
| protected function loadComment($id) { | protected function loadComment($id) { | ||||
| return PhabricatorAuditInlineComment::loadID($id); | return PhabricatorAuditInlineComment::loadID($id); | ||||
| } | } | ||||
| protected function loadCommentByPHID($phid) { | |||||
| return PhabricatorAuditInlineComment::loadPHID($phid); | |||||
| } | |||||
| protected function loadCommentForEdit($id) { | protected function loadCommentForEdit($id) { | ||||
| $request = $this->getRequest(); | $request = $this->getRequest(); | ||||
| $user = $request->getUser(); | $user = $request->getUser(); | ||||
| $inline = $this->loadComment($id); | $inline = $this->loadComment($id); | ||||
| if (!$this->canEditInlineComment($user, $inline)) { | if (!$this->canEditInlineComment($user, $inline)) { | ||||
| throw new Exception('That comment is not editable!'); | throw new Exception('That comment is not editable!'); | ||||
| } | } | ||||
| Show All 34 Lines | |||||