Skip to content
This repository has been archived by the owner on Apr 26, 2022. It is now read-only.

Commit

Permalink
Merge pull request #542 from Nosto/hotfix/3.11.4
Browse files Browse the repository at this point in the history
Hotfix 3.11.4 - Add category tagging to product tagging & Fix hidden categories
  • Loading branch information
supercid authored Dec 5, 2019
2 parents 85a5b5b + 1205cc2 commit ac5efa1
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 5 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
All notable changes to this project will be documented in this file. This project adheres to Semantic Versioning.

### 3.11.4
* Fix category tagging not being rendered on product detail page
* Fix an issue when rendering category tagging for categories in which parents are hidden

### 3.11.3
* Remove function parameter type check for compatibility with PHP < 5.6

Expand Down
5 changes: 4 additions & 1 deletion app/code/community/Nosto/Tagging/Block/Category.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,10 @@ public function getCategory()
{
try {
$category = Mage::registry('current_category');
return Nosto_Tagging_Model_Meta_Category_Builder::build($category);
if ($category) {
return Nosto_Tagging_Model_Meta_Category_Builder::build($category);
}
return null;
} catch (\Exception $e) {
Nosto_Tagging_Helper_Log::exception($e);
return null;
Expand Down
4 changes: 1 addition & 3 deletions app/code/community/Nosto/Tagging/Helper/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -265,12 +265,10 @@ public function buildCategoryString($category)
$categories = $category->getParentCategories();
$path = $category->getPathInStore();
$ids = array_reverse(explode(',', $path));
$data = array();
foreach ($ids as $id) {
if (isset($categories[$id]) && $categories[$id]->getName()) {
$data[] = $categories[$id]->getName();
} else {
$data = array();
break;
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion app/code/community/Nosto/Tagging/etc/config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
<config>
<modules>
<Nosto_Tagging>
<version>3.11.3</version>
<version>3.11.4</version>
</Nosto_Tagging>
</modules>
<global>
Expand Down
1 change: 1 addition & 0 deletions app/design/frontend/base/default/layout/nostotagging.xml
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@
<catalog_product_view>
<reference name="after_body_start">
<block type="nosto_tagging/product" name="nosto.product"/>
<block type="nosto_tagging/category" name="nosto.category"/>
</reference>
</catalog_product_view>

Expand Down

0 comments on commit ac5efa1

Please sign in to comment.