Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge pull request #7 from marijnkampf/master

BUGFIX uncaught exception method 'onmobiledomain' does not exist on 'Security'
  • Loading branch information...
commit e33fae225c1c017d009941a11dc10b44597df128 2 parents 4eb9173 + 2ecbb66
@halkyon halkyon authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  code/MobileSiteTreeExtension.php
View
2  code/MobileSiteTreeExtension.php
@@ -8,7 +8,7 @@ function MetaTags(&$tags) {
$config = SiteConfig::current_site_config();
// Ensure a canonical link is placed, for semantic correctness and SEO
- if(Controller::has_curr() && Controller::curr()->onMobileDomain() && $config->MobileSiteType == 'RedirectToDomain') {
+ if(Controller::has_curr() && Controller::curr()->hasMethod("onMobileDomain") && Controller::curr()->onMobileDomain() && $config->MobileSiteType == 'RedirectToDomain') {
$oldBaseURL = Director::baseURL();
Director::setbaseURL($config->FullSiteDomain);
$tags .= sprintf('<link rel="canonical" href="%s" />', $this->owner->AbsoluteLink()) . "\n";
Please sign in to comment.
Something went wrong with that request. Please try again.