Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
lgh06 committed Mar 2, 2022
1 parent df1b8d4 commit b82f122
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/web/src/pages/api/task.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ async function _postHandler(
let userTaskCount = await db.collection("task").countDocuments({
userId,
});
if(userTaskCount > 3){
if(userTaskCount >= 3){
return res.status(400).json({ err: 'user task count is over 3' })
}
return mongo.upsertDoc(db, 'task', filter, newDoc, res, true);
Expand Down

0 comments on commit b82f122

Please sign in to comment.