Skip to content

Commit

Permalink
Fix merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
nickbar01234 committed Apr 28, 2024
1 parent 0ba3b61 commit 4bdbdf7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
3 changes: 0 additions & 3 deletions prisma/schema.prisma
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,6 @@ model Senior {
Files File[]
ChapterID String @db.ObjectId
chapter Chapter @relation(fields: [ChapterID], references: [id], onDelete: Cascade)
chapter Chapter @relation(fields: [ChapterID], references: [id], onDelete: Cascade)
}

model File {
Expand Down Expand Up @@ -134,8 +133,6 @@ model ChapterRequest {
questions String
chapter Chapter?
chapter Chapter?
}

model Chapter {
Expand Down
10 changes: 3 additions & 7 deletions src/app/api/chapter/[chapterId]/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@ export const DELETE = withSessionAndRole(["ADMIN"], async ({ params }) => {
students: true,
seniors: true,
},
include: {
students: true,
seniors: true,
},
});

if (chapter == null) {
Expand Down Expand Up @@ -46,11 +42,11 @@ export const DELETE = withSessionAndRole(["ADMIN"], async ({ params }) => {
},
data: {
SeniorIDs: {
set: []
set: [],
},
position: "",
role: "USER"
}
role: "USER",
},
});

await prisma.chapterRequest.delete({
Expand Down

0 comments on commit 4bdbdf7

Please sign in to comment.