diff options
author | Sandro Lutz <sandro.lutz@temparus.ch> | 2017-02-07 00:12:45 +0100 |
---|---|---|
committer | Sandro Lutz <sandro.lutz@temparus.ch> | 2017-02-07 00:15:30 +0100 |
commit | fa1d607bfa951711a2c358f889db56962c179153 (patch) | |
tree | 904b6bd3b7f9d2ed133f64da22b3fb9bbfbf1842 /lib/private/Http/Client/Client.php | |
parent | ff3fa538e43bb38a5ff142b07216b9de79645c01 (diff) | |
parent | b55f5af7eaab6f827989407fa7b8d51cbb877eab (diff) | |
download | nextcloud-server-fa1d607bfa951711a2c358f889db56962c179153.tar.gz nextcloud-server-fa1d607bfa951711a2c358f889db56962c179153.zip |
Merge remote-tracking branch 'nextcloud/master'
Signed-off-by: Sandro Lutz <sandro.lutz@temparus.ch>
Diffstat (limited to 'lib/private/Http/Client/Client.php')
-rw-r--r-- | lib/private/Http/Client/Client.php | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/private/Http/Client/Client.php b/lib/private/Http/Client/Client.php index 8e182111303..4697f2e038c 100644 --- a/lib/private/Http/Client/Client.php +++ b/lib/private/Http/Client/Client.php @@ -77,9 +77,10 @@ class Client implements IClient { } } - $this->client->setDefaultOption('headers/User-Agent', 'ownCloud Server Crawler'); - if ($this->getProxyUri() !== '') { - $this->client->setDefaultOption('proxy', $this->getProxyUri()); + $this->client->setDefaultOption('headers/User-Agent', 'Nextcloud Server Crawler'); + $proxyUri = $this->getProxyUri(); + if ($proxyUri !== '') { + $this->client->setDefaultOption('proxy', $proxyUri); } } @@ -93,10 +94,10 @@ class Client implements IClient { $proxyUserPwd = $this->config->getSystemValue('proxyuserpwd', null); $proxyUri = ''; - if (!is_null($proxyUserPwd)) { + if ($proxyUserPwd !== null) { $proxyUri .= $proxyUserPwd . '@'; } - if (!is_null($proxyHost)) { + if ($proxyHost !== null) { $proxyUri .= $proxyHost; } |