1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-09-20 09:18:48 +02:00

Rename ACTION_ACCEPT into ACTION_ALLOW

Summary: Ref T603. This is "Allow" in the UI, I just mistyped it when I created the constant.

Test Plan: `grep`

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T603

Differential Revision: https://secure.phabricator.com/D7296
This commit is contained in:
epriestley 2013-10-14 12:05:11 -07:00
parent 3f5a7b31c8
commit 6c1b00fa40
3 changed files with 5 additions and 5 deletions

View file

@ -41,7 +41,7 @@ final class PhabricatorPolicyDataTestCase extends PhabricatorTestCase {
->setRules( ->setRules(
array( array(
array( array(
'action' => PhabricatorPolicy::ACTION_ACCEPT, 'action' => PhabricatorPolicy::ACTION_ALLOW,
'rule' => 'PhabricatorPolicyRuleUsers', 'rule' => 'PhabricatorPolicyRuleUsers',
'value' => array($user_a->getPHID()), 'value' => array($user_a->getPHID()),
), ),
@ -77,7 +77,7 @@ final class PhabricatorPolicyDataTestCase extends PhabricatorTestCase {
->setRules( ->setRules(
array( array(
array( array(
'action' => PhabricatorPolicy::ACTION_ACCEPT, 'action' => PhabricatorPolicy::ACTION_ALLOW,
'rule' => 'PhabricatorPolicyRuleAdministrators', 'rule' => 'PhabricatorPolicyRuleAdministrators',
'value' => null, 'value' => null,
), ),
@ -111,7 +111,7 @@ final class PhabricatorPolicyDataTestCase extends PhabricatorTestCase {
->setRules( ->setRules(
array( array(
array( array(
'action' => PhabricatorPolicy::ACTION_ACCEPT, 'action' => PhabricatorPolicy::ACTION_ALLOW,
'rule' => 'PhabricatorPolicyRuleLunarPhase', 'rule' => 'PhabricatorPolicyRuleLunarPhase',
'value' => 'new', 'value' => 'new',
), ),

View file

@ -396,7 +396,7 @@ final class PhabricatorPolicyFilter {
$action = $policy->getDefaultAction(); $action = $policy->getDefaultAction();
} }
if ($action === PhabricatorPolicy::ACTION_ACCEPT) { if ($action === PhabricatorPolicy::ACTION_ALLOW) {
return true; return true;
} }

View file

@ -3,7 +3,7 @@
final class PhabricatorPolicy final class PhabricatorPolicy
extends PhabricatorPolicyDAO { extends PhabricatorPolicyDAO {
const ACTION_ACCEPT = 'accept'; const ACTION_ALLOW = 'allow';
const ACTION_DENY = 'deny'; const ACTION_DENY = 'deny';
private $name; private $name;