override verified status
All checks were successful
backend-action / build-image (push) Successful in 25s
All checks were successful
backend-action / build-image (push) Successful in 25s
This commit is contained in:
@@ -27,6 +27,7 @@ const userUpdateSchema = userInsertSchema
|
||||
const opinionInsertSchema = createInsertSchema(userOpinion)
|
||||
.omit({
|
||||
userId: true,
|
||||
verified: true,
|
||||
})
|
||||
.array()
|
||||
.default([]);
|
||||
@@ -34,6 +35,7 @@ const opinionInsertSchema = createInsertSchema(userOpinion)
|
||||
const opinionUpdateSchema = createInsertSchema(userOpinion)
|
||||
.omit({
|
||||
userId: true,
|
||||
verified: true,
|
||||
})
|
||||
.required({ opinionId: true });
|
||||
type OpinionInsertSchema = z.infer<typeof opinionInsertSchema>;
|
||||
@@ -186,6 +188,7 @@ async function getAllUser(
|
||||
return users.map((u) => ({
|
||||
...u,
|
||||
phone: hidePhone(u.phone),
|
||||
verified: true,
|
||||
image: u.image ? `${Config.minioPublicBucketEndpoint}${u.image}` : null,
|
||||
}));
|
||||
}
|
||||
@@ -211,6 +214,7 @@ async function getUser(userId: number, showPhone: boolean) {
|
||||
image: user.image
|
||||
? `${Config.minioPublicBucketEndpoint}${user.image}`
|
||||
: null,
|
||||
verified: true,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user