From f5c34034d00df061c95e606d1d2555c2e794adc5 Mon Sep 17 00:00:00 2001 From: MGukic Date: Thu, 20 Feb 2025 15:15:26 +0100 Subject: [PATCH] fix: Fixed Constitution sidebar --- frontend/src/lib/requests/getConstitution.ts | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/frontend/src/lib/requests/getConstitution.ts b/frontend/src/lib/requests/getConstitution.ts index b4d8fa2d..86ab109a 100644 --- a/frontend/src/lib/requests/getConstitution.ts +++ b/frontend/src/lib/requests/getConstitution.ts @@ -17,17 +17,14 @@ export async function getConstitution(): Promise { const mdxSource = await serialize(mdxContent, { mdxOptions: { remarkPlugins: [remarkToc], - rehypePlugins: [ - rehypeSlug, - [rehypeToc, { headings: ["h2", "h3", "h4"] }] - ] - } + rehypePlugins: [rehypeSlug, [rehypeToc, { headings: ["h2", "h3"] }]], + }, }); return mdxSource; } catch (error) { return { error: "Error fetching and processing MDX content:", - statusCode: error.res?.statusCode || null + statusCode: error.res?.statusCode || null, }; } }