1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-01 11:12:42 +01:00
phorge-phorge/src/applications/differential/controller/DifferentialInlineCommentPreviewController.php
epriestley 6a2ae07791 Abstract access to DifferentialInlineComment behind a Query
Summary:
Ref T2222. See D6260.

Push all this junk behind a Query so I can move the storage out from underneath it.

Test Plan: Viewed home page, list view, revision. Made draft, looked at preview, submitted draft, viewed inline, replied to inline.

Reviewers: btrahan

Reviewed By: btrahan

CC: chad, aran

Maniphest Tasks: T2222

Differential Revision: https://secure.phabricator.com/D6262
2013-06-21 12:54:56 -07:00

22 lines
489 B
PHP

<?php
final class DifferentialInlineCommentPreviewController
extends PhabricatorInlineCommentPreviewController {
private $revisionID;
public function willProcessRequest(array $data) {
$this->revisionID = $data['id'];
}
protected function loadInlineComments() {
$user = $this->getRequest()->getUser();
$inlines = id(new DifferentialInlineCommentQuery())
->withDraftComments($user->getPHID(), $this->revisionID)
->execute();
return $inlines;
}
}