File tree Expand file tree Collapse file tree 4 files changed +0
-94
lines changed Expand file tree Collapse file tree 4 files changed +0
-94
lines changed Original file line number Diff line number Diff line change 14
14
*/
15
15
class Topmenu
16
16
{
17
- /**
18
- * Cache tag for menu block
19
- */
20
- private $ cacheTag = "top_menu " ;
21
-
22
17
/**
23
18
* Catalog category
24
19
*
@@ -124,7 +119,6 @@ public function beforeGetIdentities(\Magento\Theme\Block\Html\Topmenu $subject)
124
119
$ subject ->addIdentity (Category::CACHE_TAG );
125
120
$ rootId = $ this ->storeManager ->getStore ()->getRootCategoryId ();
126
121
$ storeId = $ this ->storeManager ->getStore ()->getId ();
127
- $ currentCategory = $ this ->getCurrentCategory ();
128
122
/** @var \Magento\Catalog\Model\ResourceModel\Category\Collection $collection */
129
123
$ collection = $ this ->getCategoryTree ($ storeId , $ rootId );
130
124
$ mapping = [$ rootId => $ subject ->getMenu ()]; // use nodes stack to avoid recursion
@@ -134,9 +128,6 @@ public function beforeGetIdentities(\Magento\Theme\Block\Html\Topmenu $subject)
134
128
}
135
129
$ subject ->addIdentity (Category::CACHE_TAG . '_ ' . $ category ->getId ());
136
130
}
137
- if ($ currentCategory ) {
138
- $ subject ->addIdentity ($ this ->cacheTag . '_ ' . Category::CACHE_TAG . '_ ' . $ currentCategory ->getId ());
139
- }
140
131
}
141
132
142
133
/**
Original file line number Diff line number Diff line change 13
13
<element name =" expandAll" type =" button" selector =" .tree-actions a:last-child" />
14
14
<element name =" categoryTreeRoot" type =" text" selector =" div.x-tree-root-node>li.x-tree-node:first-of-type>div.x-tree-node-el:first-of-type" timeout =" 30" />
15
15
<element name =" categoryInTree" type =" text" selector =" //a/span[contains(text(), '{{name}}')]" parameterized =" true" timeout =" 30" />
16
- <element name =" categoryHighlighted" type =" text" selector =" //ul[@id='ui-id-2']//li//a/span[contains(text(),'{{name}}')]/../.." parameterized =" true" timeout =" 30" />
17
- <element name =" categoryNotHighlighted" type =" text" selector =" ul[id=\'ui-id-2\'] li[class~=\'active\']" timeout =" 30" />
18
16
<element name =" categoryInTreeUnderRoot" type =" text" selector =" //li/ul/li[@class='x-tree-node']/div/a/span[contains(text(), '{{name}}')]" parameterized =" true" />
19
17
<element name =" lastCreatedCategory" type =" block" selector =" .x-tree-root-ct li li:last-child" />
20
18
<element name =" treeContainer" type =" block" selector =" .tree-holder" />
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -74,16 +74,6 @@ protected function getCacheLifetime()
74
74
return parent ::getCacheLifetime () ?: 3600 ;
75
75
}
76
76
77
- /**
78
- * Get cache key informative items
79
- *
80
- * @return array
81
- */
82
- public function getCacheKeyInfo ()
83
- {
84
- return array_merge (parent ::getCacheKeyInfo (), $ this ->getIdentities ());
85
- }
86
-
87
77
/**
88
78
* Get top menu html
89
79
*
You can’t perform that action at this time.
0 commit comments