From 92b9fa47d00d0549e31a151ca30c8bd41546c221 Mon Sep 17 00:00:00 2001 From: epriestley Date: Fri, 13 May 2016 11:31:58 -0700 Subject: [PATCH] Allow Herald to add package reviewers Summary: Ref T10939. Packages are valid reviewers, so let Herald "Add Reviewers" and "Add Blocking Reviewers" actions add them. Test Plan: - Wrote a rule to add package reviewers. - Hit the rule, saw a package reviewer added, viewed transcript. {F1311731} {F1311732} {F1311733} Reviewers: chad Reviewed By: chad Maniphest Tasks: T10939 Differential Revision: https://secure.phabricator.com/D15917 --- .../DifferentialReviewersAddBlockingReviewersHeraldAction.php | 2 +- .../herald/DifferentialReviewersAddReviewersHeraldAction.php | 2 +- .../differential/herald/DifferentialReviewersHeraldAction.php | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/applications/differential/herald/DifferentialReviewersAddBlockingReviewersHeraldAction.php b/src/applications/differential/herald/DifferentialReviewersAddBlockingReviewersHeraldAction.php index 79a00bc940..16d07e5240 100644 --- a/src/applications/differential/herald/DifferentialReviewersAddBlockingReviewersHeraldAction.php +++ b/src/applications/differential/herald/DifferentialReviewersAddBlockingReviewersHeraldAction.php @@ -22,7 +22,7 @@ final class DifferentialReviewersAddBlockingReviewersHeraldAction } protected function getDatasource() { - return new PhabricatorMetaMTAMailableDatasource(); + return new DiffusionAuditorDatasource(); } public function renderActionDescription($value) { diff --git a/src/applications/differential/herald/DifferentialReviewersAddReviewersHeraldAction.php b/src/applications/differential/herald/DifferentialReviewersAddReviewersHeraldAction.php index 45f209385e..d39a4370c5 100644 --- a/src/applications/differential/herald/DifferentialReviewersAddReviewersHeraldAction.php +++ b/src/applications/differential/herald/DifferentialReviewersAddReviewersHeraldAction.php @@ -22,7 +22,7 @@ final class DifferentialReviewersAddReviewersHeraldAction } protected function getDatasource() { - return new PhabricatorMetaMTAMailableDatasource(); + return new DiffusionAuditorDatasource(); } public function renderActionDescription($value) { diff --git a/src/applications/differential/herald/DifferentialReviewersHeraldAction.php b/src/applications/differential/herald/DifferentialReviewersHeraldAction.php index 5293af4311..3e98fdd92f 100644 --- a/src/applications/differential/herald/DifferentialReviewersHeraldAction.php +++ b/src/applications/differential/herald/DifferentialReviewersHeraldAction.php @@ -69,6 +69,7 @@ abstract class DifferentialReviewersHeraldAction $allowed_types = array( PhabricatorPeopleUserPHIDType::TYPECONST, PhabricatorProjectProjectPHIDType::TYPECONST, + PhabricatorOwnersPackagePHIDType::TYPECONST, ); $targets = $this->loadStandardTargets($phids, $allowed_types, $current);