Code Duplication    Length = 3-3 lines in 2 locations

lib/Elastica/Transport/Guzzle.php 1 location

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

lib/Elastica/Transport/Http.php 1 location

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