Skip to content

Commit

Permalink
Fix cs
Browse files Browse the repository at this point in the history
  • Loading branch information
atomiix committed Jul 7, 2021
1 parent 2b588d0 commit 4724361
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion ps_mainmenu.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,7 @@ public function install($delete_params = true)
if ($delete_params) {
if ($this->uninstallPrestaShop16Module()) {
Configuration::deleteByName('MOD_BLOCKTOPMENU_SEARCH');

return true;
}
if (!$this->installDb() || !Configuration::updateGlobalValue('MOD_BLOCKTOPMENU_ITEMS', 'CAT3,CAT6,CAT9')) {
Expand Down Expand Up @@ -184,12 +185,13 @@ public function uninstallPrestaShop16Module()
if ($oldModule) {
// This closure calls the parent class to prevent data to be erased
// It allows the new module to be configured without migration
$parentUninstallClosure = function() {
$parentUninstallClosure = function () {
return parent::uninstall();
};
$parentUninstallClosure = $parentUninstallClosure->bindTo($oldModule, get_class($oldModule));
$parentUninstallClosure();
}

return true;
}

Expand Down

0 comments on commit 4724361

Please sign in to comment.