fatal error: unexpectedly found nil while unwrapping an Optional value
I am testing on two devices with different iMessage accounts. I create a game on one, and make my first move.
self.activeConversation?.localParticipantIdentifier is 3B06F1E9-5741-4FE9-9CFD-A6D87B76A0F7, self.activeConversation?.remoteParticipantIdentifiers is [7E8911F7-65AE-4E42-9523-53478AC6A7F7]
When I debug the app on the other device, and tap on the message, it crashes at line 399 of TicTacToe.swift:
self.init(player: current!, opponents: opponents!, board: TicTacToe.boardFrom(json: queryItems[1].value!)!)
because current is nil.
This is because on the other device, the localParticipantIdentifier and remoteParticipantIdentifiers are completely different.
The documentation for MSConversation states that for localParticipantIdentifier: "This UUID is scoped to this device". For remoteParticipantIdentifiers: "These UUIDs are scoped to this device."
It appears that the UUIDs will not be the same on different devices.