From c399eccc38d45b1f10f0c4913962b9540dddb555 Mon Sep 17 00:00:00 2001 From: prashu0705 <142883693+prashu0705@users.noreply.github.com> Date: Fri, 31 Oct 2025 03:14:13 +0530 Subject: [PATCH] fix: import MAX_MAP_LIMIT from types.ts to resolve 1000 URL cap (#2333) * fix: import MAX_MAP_LIMIT from types.ts instead of hardcoding - Remove hardcoded MAX_MAP_LIMIT = 1000 constant from map-utils.ts - Import MAX_MAP_LIMIT from types.ts for single source of truth - Fixes map endpoint returning only 1000 URLs even with higher limits - Aligns with MAX_MAP_LIMIT = 100000 defined in types.ts Fixes #2319 * fix: import MAX_MAP_LIMIT from types.ts instead of hardcoding - Remove hardcoded MAX_MAP_LIMIT = 1000 constant from map-utils.ts - Import MAX_MAP_LIMIT from types.ts for single source of truth - Fixes map endpoint returning only 1000 URLs even with higher limits - Now correctly uses MAX_MAP_LIMIT = 100000 from types.ts Fixes #2319 --------- Co-authored-by: Prashansa Bhatia --- apps/api/src/lib/map-utils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/api/src/lib/map-utils.ts b/apps/api/src/lib/map-utils.ts index dbef33a44..c6816c694 100644 --- a/apps/api/src/lib/map-utils.ts +++ b/apps/api/src/lib/map-utils.ts @@ -4,6 +4,7 @@ import { MapDocument, scrapeOptions, ScrapeOptions, + MAX_MAP_LIMIT, } from "../controllers/v2/types"; import { crawlToCrawler, StoredCrawl } from "./crawl-redis"; import { @@ -23,7 +24,6 @@ import { Logger } from "winston"; // Max Links that "Smart /map" can return const MAX_FIRE_ENGINE_RESULTS = 500; -const MAX_MAP_LIMIT = 1000; export interface MapResult { success: boolean;