Skip to content

Commit

Permalink
Fix build error
Browse files Browse the repository at this point in the history
  • Loading branch information
dogmar committed Jul 21, 2023
1 parent b228908 commit 4b3a03f
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 5 deletions.
4 changes: 2 additions & 2 deletions pages/applications/[repo].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ import {
type GlobalProps,
propsWithGlobalSettings,
} from '@src/utils/getGlobalProps'
import { normalizeQuotes } from '@src/utils/normalizeQuotes'
import { normalizeM2mItems, normalizeQuotes } from '@src/utils/normalizeQuotes'

import { CompanyLogosSection } from '../../src/components/CompanyLogos'
import { GradientBG } from '../../src/components/layout/GradientBG'
Expand Down Expand Up @@ -434,7 +434,7 @@ export const getStaticProps: GetStaticProps<AppPageProps> = async (context) => {
quotes: normalizeQuotes(appExtras.quotes),
recipes,
...getAppMeta(thisRepo),
faqs: faqData.collapsible_lists?.[0]?.items || [],
faqs: normalizeM2mItems(faqData.collapsible_lists?.[0]) || [],
buildStackTabs,
caseStudyApps: getCaseStudyApps(
repos,
Expand Down
3 changes: 2 additions & 1 deletion pages/marketplace.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ import {
type GlobalProps,
propsWithGlobalSettings,
} from '@src/utils/getGlobalProps'
import { normalizeM2mItems } from '@src/utils/normalizeQuotes'

type PageProps = {
repositories: BasicRepo[]
Expand Down Expand Up @@ -616,7 +617,7 @@ export const getStaticProps: GetStaticProps<PageProps> = async () => {
stacks: stacks || stacksCache.filtered,
tags: tags || [],
categories: categories || [],
faqs: faqData.collapsible_lists?.[0]?.items || [],
faqs: normalizeM2mItems(faqData.collapsible_lists?.[0]) || [],
errors: [
...(reposError ? [reposError] : []),
...(stacksError ? [reposError] : []),
Expand Down
3 changes: 2 additions & 1 deletion pages/pricing.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import {
type FaqListQueryVariables,
} from '@src/generated/graphqlDirectus'
import { propsWithGlobalSettings } from '@src/utils/getGlobalProps'
import { normalizeM2mItems } from '@src/utils/normalizeQuotes'

import { PlansFeaturesTable as PlanFeaturesTable } from '../src/components/page-sections/PlansFeaturesTables'

Expand Down Expand Up @@ -247,7 +248,7 @@ export const getStaticProps: GetStaticProps<PricingPageProps> = async (
metaTitle: 'Pricing',
metaDescription: 'Flexible plans for every stage of your business',
...pricing,
faqs: faqData.collapsible_lists?.[0]?.items || [],
faqs: normalizeM2mItems(faqData.collapsible_lists?.[0]) || [],
footerVariant: FooterVariant.kitchenSink,
errors: [
...(pricingError ? [pricingError] : []),
Expand Down
3 changes: 2 additions & 1 deletion pages/solutions/[solution].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ import {
type GlobalProps,
propsWithGlobalSettings,
} from '@src/utils/getGlobalProps'
import { normalizeM2mItems } from '@src/utils/normalizeQuotes'

import { GradientBG } from '../../src/components/layout/GradientBG'
import { HeaderPad } from '../../src/components/layout/HeaderPad'
Expand Down Expand Up @@ -237,7 +238,7 @@ export const getStaticProps: GetStaticProps<AppPageProps> = async (context) => {
solution,
metaTitle: `Solution${solution.title ? ` – ${solution.title}` : ''}`,
metaDescription: solution.description || null,
faqs: faqData.collapsible_lists?.[0]?.items || [],
faqs: normalizeM2mItems(faqData.collapsible_lists?.[0]) || [],
caseStudy: solution.case_study || null,
caseStudyApps: getCaseStudyApps(
repos,
Expand Down

0 comments on commit 4b3a03f

Please sign in to comment.