add cascading delete to sessionData

This commit is contained in:
Francis Cao committed 2024-08-27 21:33:46 -07:00
1 parent ff0c825a7b
commit 13c7dd6aa8
2 files changed
+9

No files matched your search

+3
View File
@@ -171,6 +171,9 @@ export async function deleteUser(
client.eventData.deleteMany({
where: { websiteId: { in: websiteIds } },
}),
client.sessionData.deleteMany({
where: { websiteId: { in: websiteIds } },
}),
client.websiteEvent.deleteMany({
where: { websiteId: { in: websiteIds } },
}),
+6
View File
@@ -164,6 +164,9 @@ export async function resetWebsite(
client.eventData.deleteMany({
where: { websiteId },
}),
client.sessionData.deleteMany({
where: { websiteId },
}),
client.websiteEvent.deleteMany({
where: { websiteId },
}),
@@ -195,6 +198,9 @@ export async function deleteWebsite(
client.eventData.deleteMany({
where: { websiteId },
}),
client.sessionData.deleteMany({
where: { websiteId },
}),
client.websiteEvent.deleteMany({
where: { websiteId },
}),