Wisembly/elephant.io — pull request #20 by tpae (2013-06-13 20:55:03+00:00)
Title: Check empty string in curl_exec

If curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);, then $res will return empty string. The exception should be thrown if it fails to handshake, thus also checking for empty string.

http://www.php.net/manual/en/function.curl-exec.php#70123