Skip to content

Commit

Permalink
Fix back-compat for incremental programs (set deadline)
Browse files Browse the repository at this point in the history
  • Loading branch information
NathanKell authored Sep 10, 2023
1 parent 212f18d commit 6e9bb24
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Source/Programs/ProgramHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,9 @@ public void OnLoadStrategiesComplete()
{
if (p.fracElapsed < 0d)
{
p.fracElapsed = (p.lastPaymentUT - p.acceptedUT) / (p.DurationYears * (365.25d * 86400d));
double durSec = p.DurationYears * (365.25d * 86400d);
p.fracElapsed = (p.lastPaymentUT - p.acceptedUT) / durSec;
p.deadlineUT = p.acceptedUT + durSec;
}
}
_ready = true;
Expand Down

0 comments on commit 6e9bb24

Please sign in to comment.