MCPcopy Create free account
hub / github.com/monkeytypegame/monkeytype / getResult

Function getResult

backend/src/dal/result.ts:61–69  ·  view source on GitHub ↗
(uid: string, id: string)

Source from the content-addressed store, hash-verified

59}
60
61export async function getResult(uid: string, id: string): Promise<DBResult> {
62 const result = await getResultCollection().findOne({
63 _id: new ObjectId(id),
64 uid,
65 });
66
67 if (!result) throw new MonkeyError(404, "Result not found");
68 return replaceLegacyValues(result);
69}
70
71export async function getLastResult(uid: string): Promise<DBResult> {
72 const lastResult = await getResultCollection().findOne(

Callers

nothing calls this directly

Calls 2

replaceLegacyValuesFunction · 0.90
getResultCollectionFunction · 0.85

Tested by

no test coverage detected