Skip to content

Commit

Permalink
Merge pull request #185 from Markus-Gurkcity/gdprajax
Browse files Browse the repository at this point in the history
remove isset condition because variables always set
  • Loading branch information
kpodemski authored Feb 22, 2023
2 parents d49fa6a + bca23f8 commit f263e2a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions controllers/front/FrontAjaxGdpr.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,12 @@ public function display()

if ($customer->isLogged() === true) {
$token = sha1($customer->secure_key);
if (!isset($customer_token) || $customer_token == $token) {
if ($customer_token === $token) {
GDPRLog::addLog($id_customer, 'consent', $id_module);
}
} else {
$token = sha1('psgdpr' . Context::getContext()->cart->id_guest . $_SERVER['REMOTE_ADDR'] . date('Y-m-d'));
if (!isset($guest_token) || $guest_token == $token) {
if ($guest_token === $token) {
GDPRLog::addLog($id_customer, 'consent', $id_module, $id_guest);
}
}
Expand Down

0 comments on commit f263e2a

Please sign in to comment.