From 063f98b97dca0918bbfd3c6df4a3ce9dc29b4c21 Mon Sep 17 00:00:00 2001 From: James Gordon Date: Wed, 20 May 2015 09:02:29 +1000 Subject: [PATCH] Add curl_errno() to one exception --- lib/Madcoda/Youtube.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Madcoda/Youtube.php b/lib/Madcoda/Youtube.php index d536384..e2e5e17 100644 --- a/lib/Madcoda/Youtube.php +++ b/lib/Madcoda/Youtube.php @@ -472,7 +472,7 @@ public function api_get($url, $params) curl_setopt($tuCurl, CURLOPT_RETURNTRANSFER, 1); $tuData = curl_exec($tuCurl); if (curl_errno($tuCurl)) { - throw new \Exception('Curl Error : ' . curl_error($tuCurl)); + throw new \Exception('Curl Error : ' . curl_error($tuCurl), curl_errno($tuCurl)); } return $tuData; }