1
0
Fork 0

Reordered keys gitlab comes after github

pull/4670/head
Michal Gebauer 2015-12-03 14:24:26 +01:00
parent dc5f8cfbaa
commit 611f9dcfe2
1 changed files with 2 additions and 2 deletions

View File

@ -79,7 +79,7 @@ class JsonConfigSource implements ConfigSourceInterface
public function addConfigSetting($name, $value) public function addConfigSetting($name, $value)
{ {
$this->manipulateJson('addConfigSetting', $name, $value, function (&$config, $key, $val) { $this->manipulateJson('addConfigSetting', $name, $value, function (&$config, $key, $val) {
if (preg_match('{^(gitlab-oauth|github-oauth|http-basic|platform)\.}', $key)) { if (preg_match('{^(github-oauth|gitlab-oauth|http-basic|platform)\.}', $key)) {
list($key, $host) = explode('.', $key, 2); list($key, $host) = explode('.', $key, 2);
if ($this->authConfig) { if ($this->authConfig) {
$config[$key][$host] = $val; $config[$key][$host] = $val;
@ -98,7 +98,7 @@ class JsonConfigSource implements ConfigSourceInterface
public function removeConfigSetting($name) public function removeConfigSetting($name)
{ {
$this->manipulateJson('removeConfigSetting', $name, function (&$config, $key) { $this->manipulateJson('removeConfigSetting', $name, function (&$config, $key) {
if (preg_match('{^(gitlab-oauth|github-oauth|http-basic|platform)\.}', $key)) { if (preg_match('{^(github-oauth|gitlab-oauth|http-basic|platform)\.}', $key)) {
list($key, $host) = explode('.', $key, 2); list($key, $host) = explode('.', $key, 2);
if ($this->authConfig) { if ($this->authConfig) {
unset($config[$key][$host]); unset($config[$key][$host]);