MCPcopy Create free account
hub / github.com/backnotprop/plannotator / collect

Function collect

packages/shared/pr-github.ts:444–449  ·  view source on GitHub ↗
(author: any)

Source from the content-addressed store, hash-verified

442 const botLogins = new Set<string>();
443 const avatarByLogin = new Map<string, string>();
444 const collect = (author: any) => {
445 if (!author?.login) return;
446 const login = String(author.login);
447 if (author.__typename === 'Bot') botLogins.add(login);
448 if (author.avatarUrl && !avatarByLogin.has(login)) avatarByLogin.set(login, String(author.avatarUrl));
449 };
450 for (const n of (pr.comments?.nodes ?? [])) collect(n?.author);
451 for (const n of (pr.reviews?.nodes ?? [])) collect(n?.author);
452

Callers 1

fetchGhThreadsAndBotsFunction · 0.85

Calls 3

addMethod · 0.80
hasMethod · 0.80
setMethod · 0.45

Tested by

no test coverage detected