improv: simplify

This commit is contained in:
Tomasz Stefaniak 2025-06-11 15:09:08 -07:00
parent b553630f2a
commit e8ecedb36d

View file

@ -8,7 +8,6 @@ import {
import { renderChatMessage } from "../../util/messageContent";
import { getCleanUriPath } from "../../util/uri";
import { extractPathsFromCodeBlocks } from "../utils/extractPathsFromCodeBlocks";
import { RULES_MARKDOWN_FILENAME } from "./constants";
/**
* Checks if a path matches any of the provided globs
@ -90,11 +89,7 @@ const isFileInDirectory = (
* Checks if a rule is a root-level rule (.continue directory or no file path)
*/
const isRootLevelRule = (rule: RuleWithSource): boolean => {
return (
!rule.ruleFile ||
rule.ruleFile.startsWith(".continue/") ||
rule.ruleFile === `.continue/${RULES_MARKDOWN_FILENAME}`
);
return !rule.ruleFile || rule.ruleFile.startsWith(".continue/");
};
/**