Fix two cases where we load Commit handles without a viewer
I missed these in testing D5139 because they aren't in the web UIs and I am dumb and can not brain today. Auditors: vrana
This commit is contained in:
@@ -226,6 +226,7 @@ final class ManiphestTransactionEditor extends PhabricatorEditor {
|
|||||||
$phids = array_keys($phids);
|
$phids = array_keys($phids);
|
||||||
|
|
||||||
$handles = id(new PhabricatorObjectHandleData($phids))
|
$handles = id(new PhabricatorObjectHandleData($phids))
|
||||||
|
->setViewer($this->getActor())
|
||||||
->loadHandles();
|
->loadHandles();
|
||||||
|
|
||||||
$view = new ManiphestTransactionDetailView();
|
$view = new ManiphestTransactionDetailView();
|
||||||
|
|||||||
@@ -77,7 +77,13 @@ final class PhabricatorRepositoryCommitHeraldWorker
|
|||||||
$commit->getPHID(),
|
$commit->getPHID(),
|
||||||
));
|
));
|
||||||
|
|
||||||
$handles = id(new PhabricatorObjectHandleData($phids))->loadHandles();
|
// TODO: This is complicated and needs to be sorted out properly for
|
||||||
|
// repository policy stuff. We might need an omniscient user here?
|
||||||
|
$viewer = new PhabricatorUser();
|
||||||
|
|
||||||
|
$handles = id(new PhabricatorObjectHandleData($phids))
|
||||||
|
->setViewer($viewer)
|
||||||
|
->loadHandles();
|
||||||
|
|
||||||
$commit_handle = $handles[$commit->getPHID()];
|
$commit_handle = $handles[$commit->getPHID()];
|
||||||
$commit_name = $commit_handle->getName();
|
$commit_name = $commit_handle->getName();
|
||||||
|
|||||||
Reference in New Issue
Block a user