Skip to content

Commit

Permalink
Merge pull request #4 from jasonkellydk/master
Browse files Browse the repository at this point in the history
PSR-2
  • Loading branch information
jasonkellydk authored May 17, 2017
2 parents 95d6cc6 + 5721c4f commit ca68d07
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,4 @@ public function createKeywordForDomain($domainId, $keyword, $searchType, $search
* @return mixed
*/
public function deleteKeywordsForDomain($domainId, $id);

}
11 changes: 5 additions & 6 deletions src/SpotOnLive/AccuRanker/Services/CurlService.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

use SpotOnLive\AccuRanker\Options\ApiOptions;


class CurlService implements CurlServiceInterface
{
/** @var ApiOptions */
Expand All @@ -31,7 +30,7 @@ public function get($url, $token, $params = [])

curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl,CURLOPT_TIMEOUT, $this->config->get('curl_timeout'));
curl_setopt($curl, CURLOPT_TIMEOUT, $this->config->get('curl_timeout'));
curl_setopt($curl, CURLOPT_HTTPHEADER, ['Authorization:' . $token]);

$result = curl_exec($curl);
Expand All @@ -53,9 +52,9 @@ public function post($url, $token, $body = [])
$curl = curl_init();

curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl,CURLOPT_POST, 1);
curl_setopt($curl,CURLOPT_POSTFIELDS,$body);
curl_setopt($curl,CURLOPT_TIMEOUT, $this->config->get('curl_timeout'));
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS, $body);
curl_setopt($curl, CURLOPT_TIMEOUT, $this->config->get('curl_timeout'));
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_HTTPHEADER, ['Authorization:' . $token]);

Expand All @@ -77,7 +76,7 @@ public function delete($url, $token)
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_CUSTOMREQUEST, "DELETE");
curl_setopt($curl,CURLOPT_TIMEOUT, $this->config->get('curl_timeout'));
curl_setopt($curl, CURLOPT_TIMEOUT, $this->config->get('curl_timeout'));
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl, CURLOPT_HTTPHEADER, ['Authorization:' . $token]);

Expand Down

0 comments on commit ca68d07

Please sign in to comment.