Skip to content

Commit 5b1cdd8

Browse files
author
Vikas Agarwal
committed
trying to handle hidden milestones while creating them with new timeline
1 parent dcfc62b commit 5b1cdd8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/routes/timelines/create.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,9 @@ module.exports = [
9090
createdBy: req.authUser.userId,
9191
updatedBy: req.authUser.userId,
9292
};
93-
startDate = endDate.add(1, 'days');
93+
if (!mt.hidden) {
94+
startDate = endDate.add(1, 'days');
95+
}
9496
return milestone;
9597
});
9698
return models.Milestone.bulkCreate(milestones, { returning: true })

0 commit comments

Comments
 (0)