MCPcopy Create free account
hub / github.com/coder/ghostty-web / scanRow

Method scanRow

lib/link-detector.ts:88–108  ·  view source on GitHub ↗

* Scan a row for links using all registered providers

(row: number)

Source from the content-addressed store, hash-verified

86 * Scan a row for links using all registered providers
87 */
88 private async scanRow(row: number): Promise<void> {
89 this.scannedRows.add(row);
90
91 const allLinks: ILink[] = [];
92
93 // Query all providers
94 for (const provider of this.providers) {
95 const links = await new Promise<ILink[] | undefined>((resolve) => {
96 provider.provideLinks(row, resolve);
97 });
98
99 if (links) {
100 allLinks.push(...links);
101 }
102 }
103
104 // Cache all discovered links
105 for (const link of allLinks) {
106 this.cacheLink(link);
107 }
108 }
109
110 /**
111 * Cache a link for fast lookup

Callers 1

getLinkAtMethod · 0.95

Calls 2

cacheLinkMethod · 0.95
provideLinksMethod · 0.65

Tested by

no test coverage detected