1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-10 00:42:41 +01:00

Correct behavior of "writable" Almanac service binding for repository services

Summary: Ref T13611. This property worked correctly when implemented in D19357. The behavior was broken by D20775, which tested node-level routing but did not specifically re-test the "writable" property. This was difficult to spot because ref query outcomes weren't observable in the UI, and the ref itself had the correct property value.

Test Plan:
See D21575. After this change, the UI shows the correct state, rather than showing a read-only service ref as writable:

{F8465865}

Maniphest Tasks: T13611

Differential Revision: https://secure.phabricator.com/D21576
This commit is contained in:
epriestley 2021-02-25 12:10:40 -08:00
parent 39077be746
commit f970b350ea

View file

@ -1975,7 +1975,7 @@ final class PhabricatorRepository extends PhabricatorRepositoryDAO
if ($writable) {
foreach ($refs as $key => $ref) {
if (!$ref->isWritable()) {
unset($results[$key]);
unset($refs[$key]);
}
}