[-] BO : Fix bug #PSCFV-8481 no live edit on index when one language is active only

This commit is contained in:
gRoussac
2013-03-29 11:37:08 +01:00
parent 7b93630595
commit 02e7a8ca00
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -398,7 +398,7 @@ class FrontControllerCore extends Controller
$this->displayRestrictedCountryPage();
if (Tools::isSubmit('live_edit') && !$this->checkLiveEditAccess())
die(Tools::displayError());
Tools::redirect('index.php?controller=404');
$this->iso = $iso;
@@ -303,7 +303,7 @@ class AdminModulesPositionsControllerCore extends AdminController
{
$url = $this->context->shop->getBaseURL().Dispatcher::getInstance()->createUrl('index', (int)$this->context->language->id, $live_edit_params);
if (Configuration::get('PS_REWRITING_SETTINGS'))
$url = str_replace('index.php', Language::getIsoById($this->context->employee->id_lang).'/', $url);
$url = str_replace('index.php', ((count(Language::getLanguages(true)) > 1)? Language::getIsoById($this->context->employee->id_lang).'/' : ''), $url);
return $url;
}