Skip to content

Commit

Permalink
Regularly trigger ADD_CALENDAR to ensure calendar fetcher is running
Browse files Browse the repository at this point in the history
  • Loading branch information
hudashot committed Feb 25, 2019
1 parent cff2f64 commit fd121b3
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions modules/default/calendar/calendar.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,13 @@ Module.register("calendar", {
}

this.addCalendar(calendar.url, calendar.auth, calendarConfig);

// Trigger ADD_CALENDAR every fetchInterval to make sure there is always a calendar
// fetcher running on the server side.
var self = this;
setInterval(function() {
self.addCalendar(calendar.url, calendar.auth, calendarConfig);
}, self.config.fetchInterval);
}

this.calendarData = {};
Expand Down

0 comments on commit fd121b3

Please sign in to comment.