Fix unset property
This commit is contained in:
parent
cebe355800
commit
1f5e14f9f2
1 changed files with 3 additions and 3 deletions
|
@ -32,7 +32,7 @@ switch ($_SERVER['REQUEST_METHOD']) {
|
|||
$cache = new Cache\Embed($url);
|
||||
$info = $cache->get(true);
|
||||
|
||||
if ($info->url) {
|
||||
if (isset($info->url) && $info->url) {
|
||||
$code = URL::getResponseCode($info->url);
|
||||
|
||||
if (200 !== $code) {
|
||||
|
@ -144,11 +144,11 @@ switch ($_SERVER['REQUEST_METHOD']) {
|
|||
$cache = new Cache\Embed($wish_url);
|
||||
$info = $cache->get(true);
|
||||
|
||||
if (empty($wish_title)) {
|
||||
if (empty($wish_title) && isset($info->title)) {
|
||||
$wish_title = $info->title;
|
||||
}
|
||||
|
||||
if (empty($wish_description)) {
|
||||
if (empty($wish_description) && isset($info->description)) {
|
||||
$wish_description = $info->description;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue