MCPcopy
hub / github.com/Dokploy/dokploy / findUserById

Function findUserById

packages/server/src/services/admin.ts:13–27  ·  view source on GitHub ↗
(userId: string)

Source from the content-addressed store, hash-verified

11import { getWebServerSettings } from "./web-server-settings";
12
13export const findUserById = async (userId: string) => {
14 const userResult = await db.query.user.findFirst({
15 where: eq(user.id, userId),
16 // with: {
17 // account: true,
18 // },
19 });
20 if (!userResult) {
21 throw new TRPCError({
22 code: "NOT_FOUND",
23 message: "User not found",
24 });
25 }
26 return userResult;
27};
28
29export const findOrganizationById = async (organizationId: string) => {
30 const organizationResult = await db.query.organization.findFirst({

Callers 5

handlerFunction · 0.90
user.tsFile · 0.90
stripe.tsFile · 0.90
project.tsFile · 0.90
server.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected