BUGFIX ContentController::SiteConfig() should look to the SiteTree record so an alternate SiteConfig is considered, if this method doesn't exist on the data record then fall back to the default SiteConfig

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.4@111255 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sean Harvey 2010-09-27 02:30:39 +00:00 committed by Sam Minnee
parent 8b86879d59
commit 47227a9395

View File

@ -401,8 +401,12 @@ HTML;
}
function SiteConfig() {
if(method_exists($this->dataRecord, 'getSiteConfig')) {
return $this->dataRecord->getSiteConfig();
} else {
return SiteConfig::current_site_config();
}
}
/**
* Returns the xml:lang and lang attributes.