Skip to content

Commit

Permalink
Removed the hook registerGDPRConsent as the hook listener is not defined
Browse files Browse the repository at this point in the history
  • Loading branch information
Progi1984 committed Feb 15, 2022
1 parent dab5bae commit 314535c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
2 changes: 0 additions & 2 deletions psgdpr.php
Original file line number Diff line number Diff line change
Expand Up @@ -185,9 +185,7 @@ public function install()
require_once __DIR__ . '/sql/install.php'; // sql querries

$hook = [
'registerGDPRConsent',
'displayCustomerAccount',
'actionDeleteGDPRCustomer',
'displayGDPRConsent',
'actionAdminControllerSetMedia',
'additionalCustomerFormFields',
Expand Down
7 changes: 5 additions & 2 deletions upgrade/upgrade-1.4.0.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,15 @@
*/
function upgrade_module_1_4_0($module)
{
$sql = ' ALTER TABLE `' . _DB_PREFIX_ . 'psgdpr_log`
// Update database
$sql = ' ALTER TABLE `' . _DB_PREFIX_ . 'psgdpr_log`
ADD INDEX `idx_id_customer` ( `id_customer`, `id_guest`, `client_name`, `id_module`, `date_add`, `date_upd`); ';

if (Db::getInstance()->execute($sql) == false) {
return false;
}

return true;
// Remove hook
return $module->unregisterHook('registerGDPRConsent')
&& $module->unregisterHook('actionDeleteGDPRCustomer');
}

0 comments on commit 314535c

Please sign in to comment.