@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Avoid "Undefined index" error in project.search API when project_customfieldstorage table has additional fields not requested

Summary:
Do not trigger an "Undefined index" error in PhabricatorCustomFieldStorage when calling the `project.search` Conduit API without passing search parameters when the local project_customfieldstorage table has additional fields configured not requested in the API call.

Closes T15688

Test Plan: See above; `curl -k -s -X GET http://phorge.localhost/api/project.search?api.token=api-xxxxxxxxxxxx | jq -r` for comparison

Reviewers: O1 Blessed Committers, 20after4

Reviewed By: O1 Blessed Committers, 20after4

Subscribers: 20after4, tobiaswiese, valerio.bozzolan, Matthew, Cigaryno

Maniphest Tasks: T15688

Differential Revision: https://we.phorge.it/D25493

+4
+4
src/infrastructure/customfield/storage/PhabricatorCustomFieldStorage.php
··· 80 80 $object_phid = $row['objectPHID']; 81 81 $value = $row['fieldValue']; 82 82 83 + if (!isset($map[$index]) || !isset($map[$index][$object_phid])) { 84 + continue; 85 + } 86 + 83 87 $key = $map[$index][$object_phid]; 84 88 $result[$key] = $value; 85 89 }