MCPcopy
hub / github.com/callumalpass/tasknotes / removePathFromIndex

Method removePathFromIndex

src/utils/TaskManager.ts:633–651  ·  view source on GitHub ↗
(
		index: Map<string, Set<string>>,
		value: string | undefined,
		path: string
	)

Source from the content-addressed store, hash-verified

631 }
632
633 private removePathFromIndex(
634 index: Map<string, Set<string>>,
635 value: string | undefined,
636 path: string
637 ): void {
638 if (!value) {
639 return;
640 }
641
642 const paths = index.get(value);
643 if (!paths) {
644 return;
645 }
646
647 paths.delete(path);
648 if (paths.size === 0) {
649 index.delete(value);
650 }
651 }
652
653 private incrementValues(counts: Map<string, number>, values: string[]): void {
654 for (const value of values) {

Callers 1

Calls 2

getMethod · 0.65
deleteMethod · 0.65

Tested by

no test coverage detected