Remove product literal strings in "pht()", part 6
[phabricator.git] / src / applications / differential / herald / DifferentialRevisionAuthorProjectsHeraldField.php
blobbd91e810b242ed825541a70ba30731ee5cbd1465
1 <?php
3 final class DifferentialRevisionAuthorProjectsHeraldField
4 extends DifferentialRevisionHeraldField {
6 const FIELDCONST = 'differential.revision.author.projects';
8 public function getHeraldFieldName() {
9 return pht("Author's projects");
12 public function getHeraldFieldValue($object) {
13 $viewer = PhabricatorUser::getOmnipotentUser();
15 $projects = id(new PhabricatorProjectQuery())
16 ->setViewer($viewer)
17 ->withMemberPHIDs(array($object->getAuthorPHID()))
18 ->execute();
20 return mpull($projects, 'getPHID');
23 protected function getHeraldFieldStandardType() {
24 return self::STANDARD_PHID_LIST;
27 protected function getDatasource() {
28 return new PhabricatorProjectDatasource();