Merge pull request #72 from robert-h-curry/3.1-compatibility

Extension and config fixes for 3.1
This commit is contained in:
Sean Harvey 2013-04-03 19:14:27 -07:00
commit 355bb8ca8f
2 changed files with 9 additions and 10 deletions

View File

@ -5,15 +5,14 @@
* about a number of sub-sites, rather than a single site.
*/
Object::add_extension('SiteTree', 'SiteTreeSubsites');
Object::add_extension('ContentController', 'ControllerSubsites');
Object::add_extension('LeftAndMain', 'LeftAndMainSubsites');
Object::add_extension('LeftAndMain', 'ControllerSubsites');
Object::add_extension('Group', 'GroupSubsites');
Object::add_extension('File', 'FileSubsites');
Object::add_extension('ErrorPage', 'ErrorPageSubsite');
Object::add_extension('SiteConfig', 'SiteConfigSubsites');
SiteTree::add_extension('SiteTreeSubsites');
ContentController::add_extension('ControllerSubsites');
LeftAndMain::add_extension('LeftAndMainSubsites');
LeftAndMain::add_extension('ControllerSubsites');
Group::add_extension('GroupSubsites');
File::add_extension('FileSubsites');
ErrorPage::add_extension('ErrorPageSubsite');
SiteConfig::add_extension('SiteConfigSubsites');
SS_Report::add_excluded_reports('SubsiteReportWrapper');

View File

@ -10,7 +10,7 @@ class ErrorPageSubsite extends DataExtension {
* opening ErrorPage in the CMS and publish ErrorPage causes static error page to get generated incorrectly.
*/
function alternateFilepathForErrorcode($statusCode, $locale = null) {
$static_filepath = Object::get_static($this->owner->ClassName, 'static_filepath');
$static_filepath = Config::inst()->get($this->owner->ClassName, 'static_filepath');
$subdomainPart = "";
// Try to get current subsite from session