From 117d5d1c284372cc595d093fb48e031a12b33e53 Mon Sep 17 00:00:00 2001 From: vChabot Date: Thu, 3 May 2012 14:59:17 +0000 Subject: [PATCH] // fix on module when customer is not logged --- classes/Module.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/classes/Module.php b/classes/Module.php index 62f34d2f6..a184f3b56 100644 --- a/classes/Module.php +++ b/classes/Module.php @@ -1231,7 +1231,11 @@ abstract class ModuleCore $groups = array(); if (isset($context->customer)) + { $groups = $context->customer->getGroups(); + if (empty($groups)) + $groups = array(Configuration::get('PS_UNIDENTIFIED_GROUP')); + } $hookPayment = 'Payment'; if (Db::getInstance()->getValue('SELECT `id_hook` FROM `'._DB_PREFIX_.'hook` WHERE `name` = \'displayPayment\''))