Output extra meta tags only when there are any existing translations

This commit is contained in:
Michal Kleiner 2016-08-04 16:32:17 +12:00
parent 0ae31a052e
commit 4324d5b607
1 changed files with 1 additions and 1 deletions

View File

@ -1574,7 +1574,7 @@ class Translatable extends DataExtension implements PermissionProvider {
function MetaTags(&$tags) {
$template = '<link rel="alternate" type="text/html" title="%s" hreflang="%s" href="%s" />' . "\n";
$translations = $this->owner->getTranslations();
if($translations) {
if($translations->count()) {
$translations = $translations->toArray();
$translations[] = $this->owner;