2.3.0
- Fixed
getBiggerImage
option #66 - Use of exceptions to catch errors instead returns
false
:
use Embed\Embed;
//before
$info = Embed::create($url);
if ($info) {
echo $info->title;
}
//now
try {
$info = Embed::create($url);
} catch (Embed\Exceptions\InvalidUrlException $exception) {
echo 'This url is not valid: ' . $exception->getMessage();
}