MCPcopy Index your code
hub / github.com/AnswerOverflow/AnswerOverflow / findManyServersById

Function findManyServersById

packages/core/src/server.ts:183–196  ·  view source on GitHub ↗
(
	ids: string[],
	opts?: { includeKicked: boolean },
)

Source from the content-addressed store, hash-verified

181}
182
183export async function findManyServersById(
184 ids: string[],
185 opts?: { includeKicked: boolean },
186) {
187 if (ids.length === 0) return [];
188 const found = await dbReplica.query.dbServers.findMany({
189 where: inArray(dbServers.id, ids),
190 });
191 return found.map(addFlagsToServer).filter((x) => {
192 if (!opts) return true;
193 if (x.kickedTime && !opts.includeKicked) return false;
194 return true;
195 });
196}
197
198export function upsertServer(input: z.infer<typeof zServerUpsert>) {
199 return upsert({

Callers 5

listPublicThreadsFunction · 0.90
searchMessagesFunction · 0.90
auth.tsFile · 0.90
getUserPageDataFunction · 0.90
server.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected