From 23d21e1aba3e9e043dc0afb8c124daccead8e88c Mon Sep 17 00:00:00 2001 From: ikethecoder Date: Tue, 31 May 2022 21:36:17 -0700 Subject: [PATCH] hot fix for api directory --- src/nextapp/pages/devportal/api-directory/[id].tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/nextapp/pages/devportal/api-directory/[id].tsx b/src/nextapp/pages/devportal/api-directory/[id].tsx index 75030778c..baf592258 100644 --- a/src/nextapp/pages/devportal/api-directory/[id].tsx +++ b/src/nextapp/pages/devportal/api-directory/[id].tsx @@ -44,7 +44,7 @@ export const getServerSideProps: GetServerSideProps = async (context) => { const queryClient = new QueryClient(); const queryKey = ['DiscoverableDataset', id]; - !preview && + preview === 'false' && (await queryClient.prefetchQuery( queryKey, async () => await restApi(`/ds/api/v2/directory/${id}`) @@ -55,7 +55,7 @@ export const getServerSideProps: GetServerSideProps = async (context) => { id, dehydratedState: dehydrate(queryClient), queryKey, - preview: preview ? true : false, + preview: preview === 'true' ? true : false, }, }; };