Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion app/code/Magento/Theme/Block/Html/Footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ protected function _construct()
{
$this->addData(
[
'cache_lifetime' => false,
'cache_tags' => [\Magento\Store\Model\Store::CACHE_TAG, \Magento\Cms\Model\Block::CACHE_TAG],
]
);
Expand Down Expand Up @@ -123,4 +122,14 @@ public function getIdentities()
{
return [\Magento\Store\Model\Store::CACHE_TAG, \Magento\Cms\Model\Block::CACHE_TAG];
}

/**
* Get block cache life time
*
* @return int
*/
protected function getCacheLifetime()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't it be public?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @ihor-sviziev it is protected in \Magento\Framework\View\Element\AbstractBlock::getCacheLifetime

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, ok. So I approved your changes

{
return parent::getCacheLifetime() ?: 3600;
}
}