Skip to content

Commit dc47940

Browse files
committed
Restore allowing 0 configs after rebase
1 parent ee8fdad commit dc47940

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

tools/utils/categories.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,8 @@ for (const categoryId of categoryIds) {
2525

2626
for (const rule of rules) {
2727
const ruleCategories = rule.meta.docs?.categories
28-
// Throw if rule does not have a category
29-
if (!ruleCategories?.length) {
30-
throw new Error(`Rule "${rule.ruleId}" does not have any category.`)
31-
}
3228

33-
if (ruleCategories.includes(categoryId) && rule.meta.docs?.excludeFromConfig !== true) {
29+
if (ruleCategories?.includes(categoryId)) {
3430
categoriesConfig[categoryId].rules?.push(rule)
3531
}
3632
}

0 commit comments

Comments
 (0)