Skip to content

Commit

Permalink
Merge 27e2f07 into 0d7e986
Browse files Browse the repository at this point in the history
  • Loading branch information
VaibhavPage committed Jul 30, 2019
2 parents 0d7e986 + 27e2f07 commit 9214332
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion gateways/core/calendar/start.go
Expand Up @@ -102,8 +102,9 @@ func (ese *CalendarEventSourceExecutor) listenEvents(cal *calSchedule, eventSour
}

lastT := time.Now()
var location *time.Location
if cal.Timezone != "" {
location, err := time.LoadLocation(cal.Timezone)
location, err = time.LoadLocation(cal.Timezone)
if err != nil {
errorCh <- err
return
Expand All @@ -122,6 +123,9 @@ func (ese *CalendarEventSourceExecutor) listenEvents(cal *calSchedule, eventSour
select {
case tx := <-timer:
lastT = tx
if location != nil {
lastT = lastT.In(location)
}
response := &calResponse{
EventTime: tx,
UserPayload: cal.UserPayload,
Expand Down

0 comments on commit 9214332

Please sign in to comment.