diff --git a/spec/EventSubscriber/LoggedUserWishlistSubscriberSpec.php b/spec/EventSubscriber/LoggedUserWishlistSubscriberSpec.php index ff960e01..8e0e4049 100644 --- a/spec/EventSubscriber/LoggedUserWishlistSubscriberSpec.php +++ b/spec/EventSubscriber/LoggedUserWishlistSubscriberSpec.php @@ -1,5 +1,12 @@ beConstructedWith( $uriBasedSectionContext, $wishlistsResolver, - $entityManager + $entityManager, ); } @@ -40,7 +47,7 @@ public function it_is_initializable(): void public function it_returns_if_invalid_section_on_implicit_login( SectionProviderInterface $uriBasedSectionContext, UserEvent $event, - AdminSection $adminSection + AdminSection $adminSection, ): void { $uriBasedSectionContext->getSection()->willReturn($adminSection)->shouldBeCalledOnce(); @@ -54,7 +61,7 @@ public function it_returns_if_invalid_user_on_implicit_login( UserEvent $event, ShopSection $shopSection, AdminUserInterface $adminUser, - WishlistsResolverInterface $wishlistsResolver + WishlistsResolverInterface $wishlistsResolver, ): void { $uriBasedSectionContext->getSection()->willReturn($shopSection)->shouldBeCalledOnce(); $event->getUser()->willReturn($adminUser)->shouldBeCalledOnce(); @@ -73,7 +80,7 @@ public function it_assign_shop_user_to_wishlists_without_shop_user_on_login( WishlistInterface $wishlist, WishlistInterface $wishlist2, ShopUserInterface $shopUser2, - EntityManagerInterface $entityManager + EntityManagerInterface $entityManager, ): void { $wishlists = [ $wishlist->getWrappedObject(), diff --git a/src/EventSubscriber/LoggedUserWishlistSubscriber.php b/src/EventSubscriber/LoggedUserWishlistSubscriber.php index 59645926..7163d7a7 100644 --- a/src/EventSubscriber/LoggedUserWishlistSubscriber.php +++ b/src/EventSubscriber/LoggedUserWishlistSubscriber.php @@ -1,5 +1,12 @@ getSession()->setCookie($this->wishlistCookieToken); - $this->cookieSetter->setCookie($this->wishlistCookieToken, null); + $this->cookieSetter->setCookie($this->wishlistCookieToken, ''); } /**