From a800886fa4742b2dced629f2824d7b45845e471c Mon Sep 17 00:00:00 2001 From: rGaillard Date: Thu, 11 Oct 2012 09:35:45 +0000 Subject: [PATCH] // fix php notice on cart rule addition without conditions git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@17834 b9a71923-0436-4b27-9f14-aed3839534dd --- controllers/admin/AdminCartRulesController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/controllers/admin/AdminCartRulesController.php b/controllers/admin/AdminCartRulesController.php index 4ca55f874..0477eb6de 100644 --- a/controllers/admin/AdminCartRulesController.php +++ b/controllers/admin/AdminCartRulesController.php @@ -60,7 +60,7 @@ class AdminCartRulesControllerCore extends AdminController // First, check if it is not already part of the restrictions $already_restricted = false; - if (Tools::getValue('product_restriction') && is_array($rule_group_array = Tools::getValue('product_rule_group')) && count($rule_group_array)) + if (is_array($rule_group_array = Tools::getValue('product_rule_group')) && count($rule_group_array) && Tools::getValue('product_restriction')) foreach ($rule_group_array as $rule_group_id) if (is_array($rule_array = Tools::getValue('product_rule_'.$rule_group_id)) && count($rule_array)) foreach ($rule_array as $rule_id)