fix remove from favorite

This commit is contained in:
Djalim Simaila 2024-02-22 14:48:36 +00:00
parent 4611fdb400
commit 47df0d1adf

View File

@ -15,7 +15,7 @@ class FavoriteController extends AbstractController
{ {
#[Route('/remove/{album_id}', name: 'app_remove_favorite')] #[Route('/remove/{album_id}', name: 'app_remove_favorite')]
public function removeFromFavorites(int $album_id): Response public function removeFromFavorites(int $album_id,EntityManagerInterface $entityManager): Response
{ {
$user = $this->getUser(); $user = $this->getUser();
$album = $entityManager->getRepository(Album::class)->findBy( $album = $entityManager->getRepository(Album::class)->findBy(