fetchCustomvars(); if (array_key_exists("geolocation", $host->customvars)) { $nav->addItem(new NavigationItem(t('Show on map'), array( 'url' => Url::fromPath('map/', array('showHost' => $host->getName())), 'target' => '_next', 'icon' => 'globe', ))); } return $nav; } }