1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-19 21:32:43 +01:00

Use PhabricatorObjectListQuery in Herald worker

Summary: Ref T2222. Straightforward, just breaks a needless dependency.

Test Plan: Pushed and parsed a commit with "Auditors" in it.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T2222

Differential Revision: https://secure.phabricator.com/D8473
This commit is contained in:
epriestley 2014-03-09 12:47:01 -07:00
parent 7cd4e70ef2
commit 3f67430f46

View file

@ -270,10 +270,16 @@ final class PhabricatorRepositoryCommitHeraldWorker
return array();
}
$phids = DifferentialFieldSpecification::parseCommitMessageObjectList(
$matches[1],
$include_mailables = false,
$allow_partial = true);
$phids = id(new PhabricatorObjectListQuery())
->setViewer(PhabricatorUser::getOmnipotentUser())
->setAllowPartialResults(true)
->setAllowedTypes(
array(
PhabricatorPeoplePHIDTypeUser::TYPECONST,
PhabricatorProjectPHIDTypeProject::TYPECONST,
))
->setObjectList($matches[1])
->execute();
if (!$phids) {
return array();