Code Duplication    Length = 5-5 lines in 2 locations

lib/Ajde/Http/Curl.php 1 location

@@ 75-79 (lines=5) @@
72
        try {
73
            $ch = curl_init();
74
75
            if ($method == 'post') {
76
                curl_setopt($ch, CURLOPT_POST, 1);
77
            } else {
78
                curl_setopt($ch, CURLOPT_CUSTOMREQUEST, strtoupper($method));
79
            }
80
            curl_setopt($ch, CURLOPT_POSTFIELDS, $postContent);
81
            curl_setopt($ch, CURLOPT_URL,
82
                $url);            // The URL to fetch. This can also be set when initializing a session with curl_init().

lib/Ajde/Shop/Transaction/Provider/Mollie/API/Client.php 1 location

@@ 188-192 (lines=5) @@
185
        if ($http_body !== null) {
186
            $request_headers[] = 'Content-Type: application/json';
187
188
            if ($http_method == self::HTTP_POST) {
189
                curl_setopt($ch, CURLOPT_POST, 1);
190
            } else {
191
                curl_setopt($ch, CURLOPT_CUSTOMREQUEST, $http_method);
192
            }
193
            curl_setopt($ch, CURLOPT_POSTFIELDS, $http_body);
194
        }
195