Skip to content

Commit

Permalink
Better fix for issue #11
Browse files Browse the repository at this point in the history
  • Loading branch information
going-digital committed Jan 16, 2018
1 parent 3e6e839 commit c605ca2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions docs/tidetable.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,7 @@ function euroscope_ascii(n) {
}

var startDate = new Date();
startDate.setDate(startDate.getDate() - 1);
for (var day = 0; day < 14; day++) {
startDate.setDate(startDate.getDate() + 1);
var sunTimes = SunCalc.getTimes(startDate, lowestoft_gps[0], lowestoft_gps[1]);
eventsList.push({
date: sunTimes.dawn,
Expand Down Expand Up @@ -112,6 +110,7 @@ for (var day = 0; day < 14; day++) {
bearing: SunCalc.getMoonPosition(moonTimes.set, lowestoft_gps[0], lowestoft_gps[1]).azimuth
})
}
startDate.setDate(startDate.getDate() + 1);
}

/* Sort list of events */
Expand Down
2 changes: 1 addition & 1 deletion tidetable.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@ function euroscope_ascii(n) {

var startDate = new Date();
for (var day = 0; day < 14; day++) {
startDate.setDate(startDate.getDate() + 1);
var sunTimes = SunCalc.getTimes(startDate, lowestoft_gps[0], lowestoft_gps[1]);
eventsList.push({
date: sunTimes.dawn,
Expand Down Expand Up @@ -110,6 +109,7 @@ for (var day = 0; day < 14; day++) {
bearing: SunCalc.getMoonPosition(moonTimes.set, lowestoft_gps[0], lowestoft_gps[1]).azimuth
})
}
startDate.setDate(startDate.getDate() + 1);
}

/* Sort list of events */
Expand Down

0 comments on commit c605ca2

Please sign in to comment.