Local notifications not adjusting for timezones

前端 未结 2 810
逝去的感伤
逝去的感伤 2021-02-09 11:47

I\'m scheduling a local notification with an NSDate with the time set to 9pm and am setting the notification\'s timezone to UTC/GMT.

If I set the device timezone to UTC

2条回答
  •  北荒
    北荒 (楼主)
    2021-02-09 12:03

    This doesn't seem be the case for daylight savings change. I have some repeating notifications with the timezone set to the localTimeZone but since this last weekend when the clocks went forward an hour they are firing an hour later, ie at 19:00 instead of 18:00.

    Seems like when I schedule an event I will have to determine the timezone for that date and use that.

    Thanks

提交回复
热议问题