From 7721bdc7c1dfadf61e3562092a8f514598df06de Mon Sep 17 00:00:00 2001 From: Andrew Jiang Date: Fri, 6 Dec 2024 12:46:20 -0500 Subject: [PATCH] fix: without staging (#1867) --- .../docs-bundle/src/pages/api/fern-docs/search/v2/reindex.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/ui/docs-bundle/src/pages/api/fern-docs/search/v2/reindex.ts b/packages/ui/docs-bundle/src/pages/api/fern-docs/search/v2/reindex.ts index 1f4cc43e31..ae3dfa84aa 100644 --- a/packages/ui/docs-bundle/src/pages/api/fern-docs/search/v2/reindex.ts +++ b/packages/ui/docs-bundle/src/pages/api/fern-docs/search/v2/reindex.ts @@ -5,7 +5,7 @@ import { getDocsDomainNode } from "@/server/xfernhost/node"; import { getAuthEdgeConfig, getFeatureFlags } from "@fern-ui/fern-docs-edge-config"; import { SEARCH_INDEX } from "@fern-ui/fern-docs-search-server/algolia"; import { algoliaIndexSettingsTask, algoliaIndexerTask } from "@fern-ui/fern-docs-search-server/tasks"; -import { addLeadingSlash } from "@fern-ui/fern-docs-utils"; +import { addLeadingSlash, withoutStaging } from "@fern-ui/fern-docs-utils"; import { NextApiRequest, NextApiResponse } from "next/types"; export const maxDuration = 900; // 15 minutes @@ -29,7 +29,7 @@ export default async function handler(req: NextApiRequest, res: NextApiResponse) indexName: SEARCH_INDEX, environment: fdrEnvironment(), fernToken: fernToken(), - domain, + domain: withoutStaging(domain), authed: (node) => { if (authEdgeConfig == null) { return false;