From 20ca65ac678aba454ac624f5da76a025080a523b Mon Sep 17 00:00:00 2001
From: Anatole Sot <47571181+ano0002@users.noreply.github.com>
Date: Sun, 25 Feb 2024 23:52:52 +0100
Subject: [PATCH] Fixed Request Button not working on title cards
---
src/components/MusicDetails/ReleaseDetails.tsx | 9 +++------
src/components/TitleCard/index.tsx | 2 ++
2 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/src/components/MusicDetails/ReleaseDetails.tsx b/src/components/MusicDetails/ReleaseDetails.tsx
index 9f4e8289..aed9f9bb 100644
--- a/src/components/MusicDetails/ReleaseDetails.tsx
+++ b/src/components/MusicDetails/ReleaseDetails.tsx
@@ -166,16 +166,13 @@ const ReleaseDetails = ({ release }: ReleaseDetailsProp) => {
By
{data.artist.map((artist, index) => (
- <>
+
{' '}
-
+
{artist.name}
{index < data.artist.length - 1 ? ', ' : ''}
- >
+
))}
diff --git a/src/components/TitleCard/index.tsx b/src/components/TitleCard/index.tsx
index 625694f8..c96060c1 100644
--- a/src/components/TitleCard/index.tsx
+++ b/src/components/TitleCard/index.tsx
@@ -11,6 +11,7 @@ import globalMessages from '@app/i18n/globalMessages';
import { withProperties } from '@app/utils/typeHelpers';
import { Transition } from '@headlessui/react';
import { ArrowDownTrayIcon } from '@heroicons/react/24/outline';
+import type { SecondaryType } from '@server/constants/media';
import { MediaStatus } from '@server/constants/media';
import type { MediaType } from '@server/models/Search';
import Link from 'next/link';
@@ -101,6 +102,7 @@ const TitleCard = ({
onComplete={requestComplete}
onUpdating={requestUpdating}
onCancel={closeModal}
+ {...(tmdbOrMbId ? {} : { secondaryType: mediaType as SecondaryType })}
/>