From 39e2b092196d65e2aee67a76dac0ef753419c2a1 Mon Sep 17 00:00:00 2001 From: rMalie Date: Wed, 13 Jul 2011 13:26:40 +0000 Subject: [PATCH] git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@7620 b9a71923-0436-4b27-9f14-aed3839534dd --- classes/Customer.php | 2 +- classes/Shop.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/classes/Customer.php b/classes/Customer.php index c0cbb18b6..c2278a781 100644 --- a/classes/Customer.php +++ b/classes/Customer.php @@ -621,7 +621,7 @@ class CustomerCore extends ObjectModel if (!$context->cart OR !$context->cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')}) $id_address = (int)(Db::getInstance()->getValue('SELECT `id_address` FROM `'._DB_PREFIX_.'address` WHERE `id_customer` = '.(int)($id_customer).' AND `deleted` = 0 ORDER BY `id`')); else - $id_address = $cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')}; + $id_address = $context->cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')}; $ids = Address::getCountryAndState($id_address); return (int)($ids['id_country'] ? $ids['id_country'] : Configuration::get('PS_COUNTRY_DEFAULT')); } diff --git a/classes/Shop.php b/classes/Shop.php index a022b2f6b..6b0238019 100644 --- a/classes/Shop.php +++ b/classes/Shop.php @@ -460,7 +460,7 @@ class ShopCore extends ObjectModel return ($type == 'shop' || $type == 'group') ? '' : array('', ''); // Parse shopContext cookie value (E.g. s-2, g-4) - $split = explode('-', Context::getContext()->cookie); + $split = explode('-', Context::getContext()->cookie->shopContext); $shopID = $shopGroupID = ''; if (count($split) == 2) {