How to determine if there is an EKEvent pending an EKParticipationStatus (not yet accepted)?

I've already tried

if ([event participationStatus] == EKParticipantStatusPending)

and it works. But EKEvent’s participation status is not displayed, and I’m afraid to use it, because perhaps this will lead to a failure due to a private API.

I also tried to iterate over all events of event.attendees, but it seems that EKParticipant isCurrentUser is not giving the correct value. It always returns NO

  for (EKParticipant* participant in event.attendees)

  {
    if ([participant isCurrentUser])

    {
      if (participant.participantStatus == EKParticipantStatusPending)

      {
        NSLog(@"NEEDS RESPONSE");
      }

    }

  }
+3
source share
1 answer

Finally, I found a tricky way to get the job done isCurrentUserfor any member.

According to fooobar.com/questions/194198 / ... we can receive a member’s email usingEKParticipant.URL.resourceSpecifier

, , . - , - , AppleID .

, resourceSpecifier -

/aMTA3MDAxMjE0MzEwNzAwMb6Y7GrNw2OCqzA8gkpxsctNZJxrzpebHm/principal/

.

+1

All Articles