Hello!
Does anyone know how I can debug the following error: "Thread 1: Fatal error: Unexpectedly found nil while unwrapping an Optional value"?
And maybe what "nil" even means?
The error displays in the following code (line 18):
Thank you so much!
Does anyone know how I can debug the following error: "Thread 1: Fatal error: Unexpectedly found nil while unwrapping an Optional value"?
And maybe what "nil" even means?
The error displays in the following code (line 18):
Code Block func updateUI() { var letters = [String]() for letter in currentGame.formattedWord { letters.append(String(letter)) } let wordWithSpacing = letters.joined(separator: " " ) correctWordLabel.text = currentGame.formattedWord scoreLabel.text = "Wins: \(totalWins), Losses: \(totalLosses)" treeImageView.image = UIImage(named: "Tree \(currentGame.incorrectMovesRemaining)") }
Thank you so much!