mirror of
https://we.phorge.it/source/phorge.git
synced 2025-01-10 14:51:06 +01:00
Arrayish fields should always return arrays
Summary: Array-like fields in HerladCommitAdapter should always return things of type array. If they return array(...) or null, then array_*() functions sporadically break. Test Plan: Ran a PhabricatorRepositoryCommitHeraldWorker for a troublesome commit. Failed before; fails no more. Reviewers: epriestley, jungejason Reviewed By: epriestley CC: aran, Korvin, vdt Maniphest Tasks: T1385 Differential Revision: https://secure.phabricator.com/D2793
This commit is contained in:
parent
c53ed032c9
commit
83a5f1479d
1 changed files with 2 additions and 2 deletions
|
@ -175,13 +175,13 @@ final class HeraldCommitAdapter extends HeraldObjectAdapter {
|
|||
case HeraldFieldConfig::FIELD_DIFFERENTIAL_REVIEWERS:
|
||||
$revision = $this->loadDifferentialRevision();
|
||||
if (!$revision) {
|
||||
return null;
|
||||
return array();
|
||||
}
|
||||
return $revision->getReviewers();
|
||||
case HeraldFieldConfig::FIELD_DIFFERENTIAL_CCS:
|
||||
$revision = $this->loadDifferentialRevision();
|
||||
if (!$revision) {
|
||||
return null;
|
||||
return array();
|
||||
}
|
||||
return $revision->getCCPHIDs();
|
||||
default:
|
||||
|
|
Loading…
Reference in a new issue