Bug fixes on Twitter Cards

This commit is contained in:
Diego Najar 2017-10-16 19:59:23 +02:00
parent 2cb85655af
commit 72055d4366

View File

@ -85,10 +85,10 @@ class pluginTwitterCards extends Plugin {
// Get the image from the content
$src = $this->getImage($content);
if ($src!==false) {
$og['image'] = $src;
$data['image'] = $src;
} else {
if (Text::isNotEmpty($this->getValue('defaultImage'))) {
$og['image'] = $this->getValue('defaultImage');
$data['image'] = $this->getValue('defaultImage');
}
}
}