From 28169be7a74b920d88fde1142934f1a00e2266c8 Mon Sep 17 00:00:00 2001 From: Alexander Astafurov Date: Wed, 18 Sep 2013 21:40:57 -0400 Subject: [PATCH] Fix double curl bug Fixed: call to makeCurl() was doing two sequential curl requests if no $cookieSet parameter was passed. --- GoogleTranslate.php | 1 + 1 file changed, 1 insertion(+) diff --git a/GoogleTranslate.php b/GoogleTranslate.php index ab9b24f..aafe1cd 100644 --- a/GoogleTranslate.php +++ b/GoogleTranslate.php @@ -89,6 +89,7 @@ public static final function makeCurl($url, array $params = array(), $cookieSet curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $output = curl_exec($ch); + return $output; } $queryString = http_build_query($params);