diff --git a/apps/api/src/scraper/WebScraper/index.ts b/apps/api/src/scraper/WebScraper/index.ts index e8ce813..ef0c839 100644 --- a/apps/api/src/scraper/WebScraper/index.ts +++ b/apps/api/src/scraper/WebScraper/index.ts @@ -163,7 +163,7 @@ export class WebScraperDataProvider { inProgress?: (progress: Progress) => void ): Promise { - const baseURLDepth = new URL(this.urls[0]).pathname.split('/').length - 2; + const baseURLDepth = new URL(this.urls[0]).pathname.split('/').length - 1; const adjustedMaxDepth = this.maxCrawledDepth + baseURLDepth;