mirror of
https://github.com/silverstripe/silverstripe-translatable
synced 2024-10-22 11:05:59 +02:00
needs to check controller is a ContentController otherwise no AbsoluteLink
This commit is contained in:
parent
b76859b194
commit
9ba41a8ca8
@ -1574,6 +1574,7 @@ class Translatable extends DataExtension implements PermissionProvider {
|
||||
function MetaTags(&$tags) {
|
||||
if (
|
||||
($controller = Controller::curr())
|
||||
&& $controller instanceof ContentController
|
||||
&& count($controller->getRequest()->getVars())
|
||||
) {
|
||||
$tags .= '<link rel="canonical" href="'.$controller->AbsoluteLink().'" />';
|
||||
|
Loading…
Reference in New Issue
Block a user