add organization access to clients
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { FastifyInstance, FastifyReply, FastifyRequest } from "fastify";
|
||||
import { getUserByEmail, updateUser } from "../user/user.service";
|
||||
import { createSession, deleteSession, getSession } from "./auth.service";
|
||||
import { getUserByEmail, updateUserInternal } from "../user/user.service";
|
||||
import { createSession, deleteSession } from "./auth.service";
|
||||
|
||||
export async function authRoutes(fastify: FastifyInstance) {
|
||||
fastify.get(
|
||||
@@ -24,7 +24,7 @@ export async function authRoutes(fastify: FastifyInstance) {
|
||||
if (userInDb == null)
|
||||
return res.code(401).send({ error: "not_allowed" });
|
||||
|
||||
await updateUser(userInDb.pid, {
|
||||
await updateUserInternal(userInDb.pid, {
|
||||
firstName: user.givenname,
|
||||
lastName: user.familyname,
|
||||
email: user.email,
|
||||
|
||||
Reference in New Issue
Block a user