mirror of
https://we.phorge.it/source/phorge.git
synced 2025-01-08 22:01:03 +01:00
Always include the current user as a selectable policy
Summary: Ref T4136. After Passphrase, user policies work correctly in this dropdown. Providing this option improves consistency and makes it easier to create, e.g., a private repository (where "no one" does not include the viewer, because they don't own the resulting object). Test Plan: Set an object's policy to my user policy. Reviewers: btrahan Reviewed By: btrahan CC: aran Maniphest Tasks: T4136 Differential Revision: https://secure.phabricator.com/D7858
This commit is contained in:
parent
4b7f3b709d
commit
db89883447
1 changed files with 5 additions and 0 deletions
|
@ -190,6 +190,11 @@ final class PhabricatorPolicyQuery
|
|||
foreach ($projects as $project) {
|
||||
$phids[] = $project->getPHID();
|
||||
}
|
||||
|
||||
// Include the "current viewer" policy. This improves consistency, but
|
||||
// is also useful for creating private instances of normally-shared object
|
||||
// types, like repositories.
|
||||
$phids[] = $viewer->getPHID();
|
||||
}
|
||||
|
||||
$capabilities = $this->object->getCapabilities();
|
||||
|
|
Loading…
Reference in a new issue