From 53142e5913e63f436e9ce9c17e372784fd00f3e8 Mon Sep 17 00:00:00 2001 From: Tymoteusz Motylewski Date: Thu, 8 Oct 2015 09:28:03 +0200 Subject: [PATCH] [impr-#45] Do not clear product cache when saving a new product Resolves https://github.com/OpenMage/magento-lts/issues/44 --- app/code/core/Mage/Catalog/Model/Product.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/code/core/Mage/Catalog/Model/Product.php b/app/code/core/Mage/Catalog/Model/Product.php index f6fe5d55294..c1b658011e4 100644 --- a/app/code/core/Mage/Catalog/Model/Product.php +++ b/app/code/core/Mage/Catalog/Model/Product.php @@ -623,7 +623,9 @@ protected function _getResource() */ public function cleanCache() { - Mage::app()->cleanCache('catalog_product_'.$this->getId()); + if ($this->getId()) { + Mage::app()->cleanCache('catalog_product_'.$this->getId()); + } return $this; }