()
| 361 | } |
| 362 | |
| 363 | private ensureFilterIndexes(): void { |
| 364 | if (this.filterIndexesBuilt) { |
| 365 | return; |
| 366 | } |
| 367 | |
| 368 | this.clearFilterIndexes(); |
| 369 | |
| 370 | for (const file of this.app.vault.getMarkdownFiles()) { |
| 371 | if (!this.isValidFile(file.path)) { |
| 372 | continue; |
| 373 | } |
| 374 | |
| 375 | const metadata = this.app.metadataCache.getFileCache(file); |
| 376 | if (metadata?.frontmatter && this.isTaskFile(metadata.frontmatter)) { |
| 377 | const entry = this.createFilterIndexEntry(file.path, metadata.frontmatter); |
| 378 | this.addFilterIndexEntry(entry); |
| 379 | } |
| 380 | } |
| 381 | |
| 382 | this.filterIndexesBuilt = true; |
| 383 | } |
| 384 | |
| 385 | private updateFilterIndexesForFile(path: string, cache: unknown): boolean { |
| 386 | if (!this.filterIndexesBuilt) { |
no test coverage detected