BUGFIX Removed calls to Translatable::is_enabled() since it's deprecated, replaced with Object::has_extension('SiteTree', 'Translatable') instead (from r93676)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@93953 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2009-11-30 01:04:56 +00:00
parent 276a36e493
commit 51a330f594
2 changed files with 2 additions and 2 deletions

View File

@ -275,7 +275,7 @@ JS;
}
// Don't open a page from a different locale
if($record && Translatable::is_enabled() && $record->Locale && $record->Locale != Translatable::get_current_locale()) {
if($record && Object::has_extension('SiteTree', 'Translatable') && $record->Locale && $record->Locale != Translatable::get_current_locale()) {
$record = null;
}

View File

@ -119,7 +119,7 @@ class LeftAndMain extends Controller {
);
// set reading lang
if(Translatable::is_enabled() && !Director::is_ajax()) {
if(Object::has_extension('SiteTree', 'Translatable') && !Director::is_ajax()) {
Translatable::choose_site_locale(array_keys(Translatable::get_existing_content_languages('SiteTree')));
}