Deal with beginning-of-day bug

If distance is zero we can't calculate stepsPerMile. Temporary solution
is to use 1000, but later we'll just look at the previous day.
Why was this JS file committed?