Skip to content

Commit

Permalink
fix: this week
Browse files Browse the repository at this point in the history
  • Loading branch information
sajdakabir committed Nov 1, 2024
1 parent bf85354 commit 75e088b
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions apps/backend/src/services/lib/item.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,15 +72,13 @@ const getThisWeekItemsByDateRange = async (me, startDate, endDate) => {
endDate = new Date(endDate);
endDate.setUTCHours(23, 59, 59, 999);

console.log("startDate (UTC): ", startDate);
console.log("endDate (UTC): ", endDate);

const items = await Item.find({
user: me,
isArchived: false,
isDeleted: false,
spaces: { $exists: true, $eq: [] },
cycleDate: { $gte: startDate, $lte: endDate }
"cycle.startsAt": { $gte: startDate },
"cycle.endsAt": { $lte: endDate }
})
.sort({ createdAt: 1 });

Expand Down

0 comments on commit 75e088b

Please sign in to comment.