Skip to content
This repository has been archived by the owner on Dec 19, 2019. It is now read-only.

Commit

Permalink
Merge pull request #4549 from magento-performance/MC-18718
Browse files Browse the repository at this point in the history
MC-18718: store switcher set not unique version
  • Loading branch information
vzabaznov authored Jul 30, 2019
2 parents fc7fb0d + 56104ef commit bd37cbf
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,12 @@ public function __construct(
}

/**
* Update version of private content on each store switch.
*
* @param StoreInterface $fromStore store where we came from
* @param StoreInterface $targetStore store where to go to
* @param string $redirectUrl original url requested for redirect after switching
*
* @return string redirect url
* @throws CannotSwitchStoreException
*/
Expand All @@ -54,7 +57,7 @@ public function switch(StoreInterface $fromStore, StoreInterface $targetStore, s
->setHttpOnly(false);
$this->cookieManager->setPublicCookie(
\Magento\Framework\App\PageCache\Version::COOKIE_NAME,
'should_be_updated',
\uniqid('updated-', true),
$publicCookieMetadata
);
} catch (\Exception $e) {
Expand Down

0 comments on commit bd37cbf

Please sign in to comment.