You are here

function metatag_test_integration_metatags_attachments_alter in Metatag 8

Implements hook_metatags_attachments_alter().

File

tests/modules/metatag_test_integration/metatag_test_integration.module, line 11
Contains metatag_test_integration.module.

Code

function metatag_test_integration_metatags_attachments_alter(array &$attachments) {
  $title = "This is the title I want | [site:name] | Yeah!";
  if (isset($title)) {
    _metatag_test_integration_replace_tag('title', \Drupal::token()
      ->replace($title), $attachments);
  }
}