1

Number of days in goal widget off? (Read 43 times)


Muddling through

    The goal widget displays one less day than it should, which also throws off the calculations for projected mileage total. Example: today is ?April 3rd, the 93rd day of the year, but my goal widget says it's day 92. My date range is 1/1/14 to 12/31/14. It looks like the widget is calculating the difference in dates and not taking into account that the range includes both end points.

    2014 Goals: Run first trail ultra, first 100K, and see what I can do in a 24-Hour race

      wcrunner2,

      The problem wasn't that I didn't add a day.  It was caused by the way JavaScript represents time.  Even though time is expressed in UTC, it somehow takes daylight savings into account.  The loss of an hour a few weeks ago resulted in a fractional day, which is dropped from the calculation.  I corrected this and the days should be correct again.

       

      eric Smile


      Muddling through

        Thanks, Eric. I just checked and everything looks fine now.

        2014 Goals: Run first trail ultra, first 100K, and see what I can do in a 24-Hour race