User function changes

This commit is contained in:
Hri7566 2023-09-09 01:37:33 -04:00
parent 7cdcdcfa5a
commit 9da5e17587
1 changed files with 9 additions and 14 deletions

View File

@ -1,13 +1,6 @@
import { User } from "@prisma/client";
import { prisma } from "./prisma";
export interface UserFlags {
freeze_name: number;
"no chat rate limit": number;
chat_curse_1: number;
chat_curse_2: number;
override_id: string;
}
import { UserFlags } from "../util/types";
export async function createUser(
_id: string,
@ -33,12 +26,14 @@ export async function readUser(_id: string) {
if (!data) return null;
return {
_id: data.id,
name: data.name,
color: data.color,
flags: data.flags
};
// return {
// _id: data.id,
// name: data.name,
// color: data.color,
// flags: data.flags
// };
return data;
}
export async function updateUser(