Updated redis client. Soft deletes reset username.

This commit is contained in:
Mike Cao 2023-05-05 21:16:13 -07:00
parent 37b94e5b96
commit e92d958b24
6 changed files with 11 additions and 37 deletions

View file

@ -1,4 +1,5 @@
import { Prisma, Team, TeamUser } from '@prisma/client';
import { getRandomChars } from 'next-basics';
import cache from 'lib/cache';
import { ROLES } from 'lib/constants';
import prisma from 'lib/prisma';
@ -222,6 +223,7 @@ export async function deleteUser(
cloudMode
? client.user.update({
data: {
username: getRandomChars(32),
deletedAt: new Date(),
},
where: {