Changeset View
Changeset View
Standalone View
Standalone View
src/applications/repository/storage/PhabricatorRepository.php
| Show First 20 Lines • Show All 2,252 Lines • ▼ Show 20 Lines | public function newConduitClientForRequest(ConduitAPIRequest $request) { | ||||
| $client = $this->newConduitClient( | $client = $this->newConduitClient( | ||||
| $viewer, | $viewer, | ||||
| $is_cluster_request); | $is_cluster_request); | ||||
| return $client; | return $client; | ||||
| } | } | ||||
| public function newConduitFuture( | |||||
| PhabricatorUser $viewer, | |||||
| $method, | |||||
| array $params, | |||||
| $never_proxy = false) { | |||||
| $client = $this->newConduitClient( | |||||
| $viewer, | |||||
| $never_proxy); | |||||
| if (!$client) { | |||||
| $result = id(new ConduitCall($method, $params)) | |||||
| ->setUser($viewer) | |||||
| ->execute(); | |||||
| $future = new ImmediateFuture($result); | |||||
| } else { | |||||
| $future = $client->callMethod($method, $params); | |||||
| } | |||||
| return $future; | |||||
| } | |||||
| public function getPassthroughEnvironmentalVariables() { | public function getPassthroughEnvironmentalVariables() { | ||||
| $env = $_ENV; | $env = $_ENV; | ||||
| if ($this->isGit()) { | if ($this->isGit()) { | ||||
| // $_ENV does not populate in CLI contexts if "E" is missing from | // $_ENV does not populate in CLI contexts if "E" is missing from | ||||
| // "variables_order" in PHP config. Currently, we do not require this | // "variables_order" in PHP config. Currently, we do not require this | ||||
| // to be configured. Since it may not be, explicitly bring expected Git | // to be configured. Since it may not be, explicitly bring expected Git | ||||
| // environmental variables into scope. This list is not exhaustive, but | // environmental variables into scope. This list is not exhaustive, but | ||||
| ▲ Show 20 Lines • Show All 591 Lines • Show Last 20 Lines | |||||