1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-26 15:30:58 +01:00

Check policy.locked slightly sooner in PhabricatorApplication

Summary: We could still miss this if the policy had never been customized and we returned early after one of the other checks.

Test Plan:
Works great on instances now.

{F267067}

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Differential Revision: https://secure.phabricator.com/D11374
This commit is contained in:
epriestley 2015-01-13 12:39:58 -08:00
parent 551823ecc4
commit ad9af106ee

View file

@ -442,6 +442,11 @@ abstract class PhabricatorApplication implements PhabricatorPolicyInterface {
return null;
}
$policy_locked = PhabricatorEnv::getEnvConfig('policy.locked');
if (isset($policy_locked[$capability])) {
return $policy_locked[$capability];
}
$config = PhabricatorEnv::getEnvConfig('phabricator.application-settings');
$app = idx($config, $this->getPHID());
@ -454,11 +459,6 @@ abstract class PhabricatorApplication implements PhabricatorPolicyInterface {
return null;
}
$policy_locked = PhabricatorEnv::getEnvConfig('policy.locked');
if (isset($policy_locked[$capability])) {
return $policy_locked[$capability];
}
return idx($policy, $capability);
}