Skip to content

Commit

Permalink
fix goal start before cal start
Browse files Browse the repository at this point in the history
  • Loading branch information
Tijl Leenders committed Mar 21, 2024
1 parent 5f3b49d commit fedff66
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/models/goal.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ impl Goal {
parent_goal: Option<Goal>,
) -> (NaiveDateTime, NaiveDateTime) {
let mut adjusted_goal_start = self.start;
if self.start.year() == 1970 {
if self.start.year() == 1970 || self.start < calendar.start_date_time {
adjusted_goal_start = calendar.start_date_time;
}
let mut adjusted_goal_deadline = self.deadline;
Expand Down

0 comments on commit fedff66

Please sign in to comment.