1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-22 13:30:55 +01:00

Fixes T10805. When clustering is not configured, this check should just

return.

Auditors: chad
This commit is contained in:
epriestley 2016-04-14 04:26:52 -07:00
parent 91479e2832
commit 0379cc10ac

View file

@ -782,6 +782,11 @@ final class PhabricatorEnv extends Phobject {
} }
public static function isClusterRemoteAddress() { public static function isClusterRemoteAddress() {
$cluster_addresses = self::getEnvConfig('cluster.addresses');
if (!$cluster_addresses) {
return false;
}
$address = idx($_SERVER, 'REMOTE_ADDR'); $address = idx($_SERVER, 'REMOTE_ADDR');
if (!$address) { if (!$address) {
throw new Exception( throw new Exception(