MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / findFirst

Function findFirst

packages/core/fumadb/src/adapters/prisma/query.ts:255–268  ·  view source on GitHub ↗
(table, v)

Source from the content-addressed store, hash-verified

253 )._all;
254 },
255 async findFirst(table, v) {
256 await init;
257 const model = getPrismaModel(table);
258 const options = createFindOptions(table, v);
259 delete options.take;
260
261 const result = await model.findFirst({
262 ...options,
263 where: options.where!,
264 });
265 if (result) return mapResult(result, table);
266
267 return null;
268 },
269 async findMany(table, v) {
270 await init;
271 const model = getPrismaModel(table);

Callers

nothing calls this directly

Calls 3

getPrismaModelFunction · 0.85
createFindOptionsFunction · 0.85
mapResultFunction · 0.70

Tested by

no test coverage detected