Changeset View
Changeset View
Standalone View
Standalone View
src/applications/policy/storage/PhabricatorPolicy.php
Show First 20 Lines • Show All 260 Lines • ▼ Show 20 Lines | switch ($policy) { | ||||
->withPHIDs(array($policy)) | ->withPHIDs(array($policy)) | ||||
->executeOne(); | ->executeOne(); | ||||
$type = phid_get_type($policy); | $type = phid_get_type($policy); | ||||
if ($type == PhabricatorProjectProjectPHIDType::TYPECONST) { | if ($type == PhabricatorProjectProjectPHIDType::TYPECONST) { | ||||
return pht( | return pht( | ||||
'Members of a particular project can take this action. (You '. | 'Members of a particular project can take this action. (You '. | ||||
'can not see this object, so the name of this project is '. | 'can not see this object, so the name of this project is '. | ||||
'restricted.)', | 'restricted.)'); | ||||
$handle->getFullName()); | |||||
} else if ($type == PhabricatorPeopleUserPHIDType::TYPECONST) { | } else if ($type == PhabricatorPeopleUserPHIDType::TYPECONST) { | ||||
return pht( | return pht( | ||||
'%s can take this action.', | '%s can take this action.', | ||||
$handle->getFullName()); | $handle->getFullName()); | ||||
} else if ($type == PhabricatorPolicyPHIDTypePolicy::TYPECONST) { | } else if ($type == PhabricatorPolicyPHIDTypePolicy::TYPECONST) { | ||||
return pht( | return pht( | ||||
'This object has a custom policy controlling who can take this '. | 'This object has a custom policy controlling who can take this '. | ||||
'action.'); | 'action.'); | ||||
▲ Show 20 Lines • Show All 237 Lines • Show Last 20 Lines |