Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2893121
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
2 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/src/applications/differential/herald/DifferentialDiffAuthorProjectsHeraldField.php b/src/applications/differential/herald/DifferentialDiffAuthorProjectsHeraldField.php
index bec1e2a66c..e484a66ce6 100644
--- a/src/applications/differential/herald/DifferentialDiffAuthorProjectsHeraldField.php
+++ b/src/applications/differential/herald/DifferentialDiffAuthorProjectsHeraldField.php
@@ -1,26 +1,31 @@
<?php
final class DifferentialDiffAuthorProjectsHeraldField
extends DifferentialDiffHeraldField {
const FIELDCONST = 'differential.diff.author.projects';
public function getHeraldFieldName() {
return pht("Author's projects");
}
public function getHeraldFieldValue($object) {
- return PhabricatorEdgeQuery::loadDestinationPHIDs(
- $object->getAuthorPHID(),
- PhabricatorProjectMemberOfProjectEdgeType::EDGECONST);
+ $viewer = PhabricatorUser::getOmnipotentUser();
+
+ $projects = id(new PhabricatorProjectQuery())
+ ->setViewer($viewer)
+ ->withMemberPHIDs(array($object->getAuthorPHID()))
+ ->execute();
+
+ return mpull($projects, 'getPHID');
}
protected function getHeraldFieldStandardType() {
return self::STANDARD_PHID_LIST;
}
protected function getDatasource() {
- return new PhabricatorProjectOrUserDatasource();
+ return new PhabricatorProjectDatasource();
}
}
diff --git a/src/applications/differential/herald/DifferentialRevisionAuthorProjectsHeraldField.php b/src/applications/differential/herald/DifferentialRevisionAuthorProjectsHeraldField.php
index cb916fcf3d..bd91e810b2 100644
--- a/src/applications/differential/herald/DifferentialRevisionAuthorProjectsHeraldField.php
+++ b/src/applications/differential/herald/DifferentialRevisionAuthorProjectsHeraldField.php
@@ -1,26 +1,31 @@
<?php
final class DifferentialRevisionAuthorProjectsHeraldField
extends DifferentialRevisionHeraldField {
const FIELDCONST = 'differential.revision.author.projects';
public function getHeraldFieldName() {
return pht("Author's projects");
}
public function getHeraldFieldValue($object) {
- return PhabricatorEdgeQuery::loadDestinationPHIDs(
- $object->getAuthorPHID(),
- PhabricatorProjectMemberOfProjectEdgeType::EDGECONST);
+ $viewer = PhabricatorUser::getOmnipotentUser();
+
+ $projects = id(new PhabricatorProjectQuery())
+ ->setViewer($viewer)
+ ->withMemberPHIDs(array($object->getAuthorPHID()))
+ ->execute();
+
+ return mpull($projects, 'getPHID');
}
protected function getHeraldFieldStandardType() {
return self::STANDARD_PHID_LIST;
}
protected function getDatasource() {
return new PhabricatorProjectDatasource();
}
}
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Sun, Jan 19, 17:53 (1 w, 5 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1127167
Default Alt Text
(2 KB)
Attached To
Mode
rP Phorge
Attached
Detach File
Event Timeline
Log In to Comment