Merge branch 'development' of https://github.com/PrestaShop/PrestaShop into development

This commit is contained in:
Gregory Roussac
2013-01-07 16:56:04 +01:00
+8 -3
View File
@@ -64,13 +64,18 @@ class TaxRulesTaxManagerCore implements TaxManagerInterface
*/
public function getTaxCalculator()
{
static $tax_enabled = null;
if (isset($this->tax_calculator))
return $this->tax_calculator;
if ($tax_enabled === null)
$tax_enabled = Configuration::get('PS_TAX');
if (!$tax_enabled)
return new TaxCalculator(array());
$taxes = array();
if (!Configuration::get('PS_TAX'))
return new TaxCalculator($taxes);
$postcode = 0;
if (!empty($this->address->postcode))
$postcode = $this->address->postcode;