diff --git a/controllers/admin/AdminPsThemeCustoConfiguration.php b/controllers/admin/AdminPsThemeCustoConfiguration.php index ce08a4d..f19da7f 100755 --- a/controllers/admin/AdminPsThemeCustoConfiguration.php +++ b/controllers/admin/AdminPsThemeCustoConfiguration.php @@ -482,7 +482,13 @@ public function ajaxProcessUpdateModule() 'moduleActionsNames' => $this->moduleActionsNames, ]); - $this->ajaxDie($this->context->smarty->fetch(__DIR__ . '/../../views/templates/admin/controllers/' . $this->controller_quick_name . '/elem/module_actions.tpl')); + $tplPath = $this->context->smarty->fetch(__DIR__ . '/../../views/templates/admin/controllers/' . $this->controller_quick_name . '/elem/module_actions.tpl'); + if (version_compare(_PS_VERSION_, '1.7.5', '>=')) { + $this->ajaxRender($tplPath); + exit; + } else { + $this->ajaxDie($tplPath); + } } /** diff --git a/tests/phpstan/phpstan-1.7.1.2.neon b/tests/phpstan/phpstan-1.7.1.2.neon index b853e72..0d56317 100644 --- a/tests/phpstan/phpstan-1.7.1.2.neon +++ b/tests/phpstan/phpstan-1.7.1.2.neon @@ -5,3 +5,4 @@ parameters: ignoreErrors: - '#Access to an undefined property Cookie::\$profile.#' - '#Call to static method getInstance\(\) on an unknown class PrestaShop\\PrestaShop\\Adapter\\SymfonyContainer.#' + - '#Call to an undefined method AdminPsThemeCustoConfigurationController::ajaxRender\(\).#' diff --git a/tests/phpstan/phpstan-1.7.2.5.neon b/tests/phpstan/phpstan-1.7.2.5.neon index b853e72..0d56317 100644 --- a/tests/phpstan/phpstan-1.7.2.5.neon +++ b/tests/phpstan/phpstan-1.7.2.5.neon @@ -5,3 +5,4 @@ parameters: ignoreErrors: - '#Access to an undefined property Cookie::\$profile.#' - '#Call to static method getInstance\(\) on an unknown class PrestaShop\\PrestaShop\\Adapter\\SymfonyContainer.#' + - '#Call to an undefined method AdminPsThemeCustoConfigurationController::ajaxRender\(\).#' diff --git a/tests/phpstan/phpstan-1.7.3.4.neon b/tests/phpstan/phpstan-1.7.3.4.neon index 01b0e1a..4908bb5 100644 --- a/tests/phpstan/phpstan-1.7.3.4.neon +++ b/tests/phpstan/phpstan-1.7.3.4.neon @@ -4,3 +4,4 @@ includes: parameters: ignoreErrors: - '#Access to an undefined property Cookie::\$profile.#' + - '#Call to an undefined method AdminPsThemeCustoConfigurationController::ajaxRender\(\).#' diff --git a/tests/phpstan/phpstan-1.7.4.4.neon b/tests/phpstan/phpstan-1.7.4.4.neon index 01b0e1a..4908bb5 100644 --- a/tests/phpstan/phpstan-1.7.4.4.neon +++ b/tests/phpstan/phpstan-1.7.4.4.neon @@ -4,3 +4,4 @@ includes: parameters: ignoreErrors: - '#Access to an undefined property Cookie::\$profile.#' + - '#Call to an undefined method AdminPsThemeCustoConfigurationController::ajaxRender\(\).#' diff --git a/tests/phpstan/phpstan-1.7.5.1.neon b/tests/phpstan/phpstan-1.7.5.1.neon index 01b0e1a..83111f1 100644 --- a/tests/phpstan/phpstan-1.7.5.1.neon +++ b/tests/phpstan/phpstan-1.7.5.1.neon @@ -4,3 +4,4 @@ includes: parameters: ignoreErrors: - '#Access to an undefined property Cookie::\$profile.#' + - '#Parameter \#1 \$value of method ControllerCore::ajaxRender\(\) expects null, string given.#' diff --git a/tests/phpstan/phpstan-1.7.6.neon b/tests/phpstan/phpstan-1.7.6.neon index 01b0e1a..83111f1 100644 --- a/tests/phpstan/phpstan-1.7.6.neon +++ b/tests/phpstan/phpstan-1.7.6.neon @@ -4,3 +4,4 @@ includes: parameters: ignoreErrors: - '#Access to an undefined property Cookie::\$profile.#' + - '#Parameter \#1 \$value of method ControllerCore::ajaxRender\(\) expects null, string given.#' diff --git a/tests/phpstan/phpstan-1.7.7.neon b/tests/phpstan/phpstan-1.7.7.neon index 01b0e1a..83111f1 100644 --- a/tests/phpstan/phpstan-1.7.7.neon +++ b/tests/phpstan/phpstan-1.7.7.neon @@ -4,3 +4,4 @@ includes: parameters: ignoreErrors: - '#Access to an undefined property Cookie::\$profile.#' + - '#Parameter \#1 \$value of method ControllerCore::ajaxRender\(\) expects null, string given.#'