MCPcopy Index your code
hub / github.com/braintrustdata/bash-agent-evals / getOrCreateUser

Function getOrCreateUser

src/data/codemode-transform.ts:83–94  ·  view source on GitHub ↗
(login: string, id: number)

Source from the content-addressed store, hash-verified

81const pullsMap = new Map<string, Pull>(); // key: "owner/repo#number"
82
83function getOrCreateUser(login: string, id: number): User {
84 if (!usersMap.has(login)) {
85 usersMap.set(login, {
86 id,
87 login,
88 issuesOpened: 0,
89 prsOpened: 0,
90 commentsMade: 0,
91 });
92 }
93 return usersMap.get(login)!;
94}
95
96function getOrCreateRepo(repoName: string, repoId: number): Repo {
97 if (!reposMap.has(repoName)) {

Callers 1

processEventFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected