Skip to content

Commit

Permalink
fix: Update deleteTask method parameter name to taskId
Browse files Browse the repository at this point in the history
  • Loading branch information
Daaaiii committed Jun 5, 2024
1 parent 55a2f7c commit 9e0d02d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/modules/task/task.repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,17 +112,17 @@ export class TaskRepository {
}

async validateParent(parentId: string) {
return await this.prisma.parentProfile.findUnique({
return this.prisma.parentProfile.findFirst({
where: {
id: parentId,
},
});
}

async deleteTask(id: number) {
async deleteTask(taskId: number) {
await this.prisma.task
.delete({
where: { id },
where: { id: taskId },
})
.catch((error) => handleErrors(error));
}
Expand Down

0 comments on commit 9e0d02d

Please sign in to comment.