Skip to content

Commit

Permalink
fixed datacite#2211 (#398)
Browse files Browse the repository at this point in the history
  • Loading branch information
bklaing2 authored Oct 9, 2024
1 parent 945a3b7 commit d9914ef
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app/doi.org/[...doi]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ interface Props {


export async function generateMetadata({ params }: Props): Promise<Metadata> {
const doi = params.doi.join('/')
const doi = decodeURIComponent(params.doi.join('/'))

const { data } = await apolloClient.query<MetadataQueryData, MetadataQueryVar>({
query: DOI_METADATA_QUERY,
Expand Down Expand Up @@ -117,7 +117,7 @@ function mapSearchparams(searchParams: Props['searchParams']) {


export default async function Page({ params, searchParams }: Props) {
const doi = params.doi.join('/')
const doi = decodeURIComponent(params.doi.join('/'))
const { connectionType, isBot, ...vars } = mapSearchparams(searchParams)
const variables = { id: doi, ...vars }

Expand Down Expand Up @@ -153,7 +153,7 @@ export default async function Page({ params, searchParams }: Props) {
<Content variables={variables} isBot={JSON.parse(isBot)} />
</Suspense>
<Suspense>
<RelatedAggregateGraph doi={doi} isBot={JSON.parse(isBot)} />
<RelatedAggregateGraph doi={doi} isBot={JSON.parse(isBot)} />
</Suspense>
<RelatedContent variables={variables} showSankey={showSankey} connectionType={connectionType} isBot={JSON.parse(isBot)} />
<Script type="application/ld+json" id="schemaOrg">{data.work.schemaOrg}</Script>
Expand Down

0 comments on commit d9914ef

Please sign in to comment.