Skip to content

Commit

Permalink
fix: correctly display "more in <language>" on details page
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinstadler committed Dec 10, 2024
1 parent 6982a31 commit 5501aca
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion app/[locale]/publications/[id]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ function translatorIndices(pub: Publication): Array<[Translator, Array<number>]>
export default async function PublicationPage(props: PublicationPageProps) {
const t = await getTranslations("PublicationPage");
const ct = await getTranslations("BernhardCategories");
const lt = await getTranslations("Languages");
const pub = await getPublication(props.params.id);
if (!pub) {
return notFound();
Expand Down Expand Up @@ -167,7 +168,11 @@ export default async function PublicationPage(props: PublicationPageProps) {

<section>
<h2 className="pt-10 font-bold">
{t("more_in")} {pub.language}
{t("more_in")}{" "}
{
// eslint-disable-next-line @typescript-eslint/no-explicit-any
lt(pub.language as any)
}
</h2>
<div className="flex">
{(await getSameLanguagePublications(pub)).map((p) => {
Expand Down

0 comments on commit 5501aca

Please sign in to comment.