I have code like:
let calendars = EKEventStore().calendars(for: entityType)
for calendar in calendars {
...
createListFrom(calendar: calendar, entityType: entityType)
}
...
newList.name = calendar.title
In iOS 10, calendar.title
is real name, but in iOS 11 it is always nil
.
Is it an iOS 11 bug or am I doing something wrong?
My Problem in this line
let calendars = EKEventStore().calendars(for: entityType)
But it works that way
let eventStore = EKEventStore()
let calendars = eventStore.calendars(for: .event)
For calendar use the below lines of code.