Fixed some issues with exporting calendar and updating calendar.