Skip to content

Commit

Permalink
chore: fix robots tests
Browse files Browse the repository at this point in the history
  • Loading branch information
harlan-zw committed Sep 29, 2024
1 parent 24e134d commit 722522d
Show file tree
Hide file tree
Showing 2 changed files with 402 additions and 51 deletions.
5 changes: 4 additions & 1 deletion packages/core/src/discovery/robotsTxt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,10 @@ export function matchPathToRule(path: string, _rules: RobotsTxtRule[]): RobotsTx
i++
}

return matchedRule
return matchedRule || {
pattern: '',
allow: true,
}
}

export function mergeRobotsTxtConfig(config: ResolvedUserConfig, { groups, sitemaps }: RobotsTxtParsed): void {
Expand Down
Loading

0 comments on commit 722522d

Please sign in to comment.