X-Git-Url: http://www.aleph1.co.uk/gitweb/?a=blobdiff_plain;f=web%2Fmodules%2Fcontrib%2Fmetatag%2Ftests%2Fmodules%2Fmetatag_test_custom_route%2Fmetatag_test_custom_route.module;fp=web%2Fmodules%2Fcontrib%2Fmetatag%2Ftests%2Fmodules%2Fmetatag_test_custom_route%2Fmetatag_test_custom_route.module;h=3c6ed8a85a5a8e578a8f50f99ab22ee0c0c7fbc5;hb=a2bd1bf0c2c1f1a17d188f4dc0726a45494cefae;hp=0000000000000000000000000000000000000000;hpb=57c063afa3f66b07c4bbddc2d6129a96d90f0aad;p=yaffs-website diff --git a/web/modules/contrib/metatag/tests/modules/metatag_test_custom_route/metatag_test_custom_route.module b/web/modules/contrib/metatag/tests/modules/metatag_test_custom_route/metatag_test_custom_route.module new file mode 100644 index 000000000..3c6ed8a85 --- /dev/null +++ b/web/modules/contrib/metatag/tests/modules/metatag_test_custom_route/metatag_test_custom_route.module @@ -0,0 +1,35 @@ +' . t('About') . ''; + $output .= '

' . t('Support module for testing handling of a custom route.') . '

'; + return $output; + + default: + } +} + +/** + * Implements hook_metatag_route_entity(). + */ +function metatag_test_custom_route_metatag_route_entity(RouteMatchInterface $route_match) { + if ($route_match->getRouteName() === 'metatag_test_custom_route.entity_route') { + if ($entity_test = $route_match->getParameter('entity_test')) { + return $entity_test; + } + } +}