With the recent changes requiring builds to be done on xcode 13, we have run into a problem where on iOS 15 ONLY, UIButtons are checking themselves. In this particular situation, we have a button that, when "Yes" is clicked, a drop box appears below the question and indexes as such. Currently, the way this is written has tableView.reloadData() which allows the text box to appear. In iOS 14 and below, this causes no additional issues. In iOS15, when clicking the "Yes" or "No" button on the first question, the question directly below is also lights up. In other parts of the app, I could simply remove this for iOS15 and it worked just fine but due to the requirement for making the text box appear, this one wont allow for this.
See code here for the Reload
func didAnswerExpansionQuestion(itemKey: String, answer: Int) {
var indexToAdjust = -1
for (index, question) in questionsArray.enumerated() {
if question["expansionItem"] != nil && question["expansionItem"] as! String == itemKey {
indexToAdjust = index
print (questionsArray.count)
}
}
adjustCells(itemIndex: indexToAdjust, key: itemKey, answer: answer)
cmhReferralTableView.reloadData()