Code Duplication    Length = 3-3 lines in 2 locations

lib/Elastica/Transport/Guzzle.php 1 location

@@ 69-71 (lines=3) @@
66
        $proxy = $connection->getProxy();
67
68
        // See: https://github.com/facebook/hhvm/issues/4875
69
        if (is_null($proxy) && defined('HHVM_VERSION')) {
70
            $proxy = getenv('http_proxy') ?: null;
71
        }
72
73
        if (!is_null($proxy)) {
74
            $options['proxy'] = $proxy;

lib/Elastica/Transport/Http.php 1 location

@@ 96-98 (lines=3) @@
93
        $proxy = $connection->getProxy();
94
95
        // See: https://github.com/facebook/hhvm/issues/4875
96
        if (is_null($proxy) && defined('HHVM_VERSION')) {
97
            $proxy = getenv('http_proxy') ?: null;
98
        }
99
100
        if (!is_null($proxy)) {
101
            curl_setopt($conn, CURLOPT_PROXY, $proxy);