From 61c6d63c6772c91214171dea1f415017d3f01116 Mon Sep 17 00:00:00 2001 From: Shadowfacts Date: Mon, 15 Jun 2020 18:36:04 -0400 Subject: [PATCH] Fix profile fields not displaying Closes #96 --- .../Views/Profile Header/ProfileHeaderTableViewCell.swift | 7 ++++--- Tusker/Views/Profile Header/ProfileHeaderTableViewCell.xib | 7 +++---- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.swift b/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.swift index bd4e5af3..f7f0cde9 100644 --- a/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.swift +++ b/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.swift @@ -28,7 +28,7 @@ class ProfileHeaderTableViewCell: UITableViewCell { @IBOutlet weak var noteTextView: StatusContentTextView! @IBOutlet weak var fieldsStackView: UIStackView! @IBOutlet weak var fieldNamesStackView: UIStackView! - @IBOutlet weak var fieldValuesStack: UIStackView! + @IBOutlet weak var fieldValuesStackView: UIStackView! @IBOutlet weak var moreButtonVisualEffectView: UIVisualEffectView! var accountID: String! @@ -102,7 +102,8 @@ class ProfileHeaderTableViewCell: UITableViewCell { fieldsStackView.isHidden = account.fields.isEmpty - fieldsStackView.arrangedSubviews.forEach { $0.removeFromSuperview() } + fieldNamesStackView.arrangedSubviews.forEach { $0.removeFromSuperview() } + fieldValuesStackView.arrangedSubviews.forEach { $0.removeFromSuperview() } for field in account.fields { let nameLabel = UILabel() nameLabel.text = field.name @@ -119,7 +120,7 @@ class ProfileHeaderTableViewCell: UITableViewCell { valueTextView.textAlignment = .left valueTextView.awakeFromNib() valueTextView.navigationDelegate = delegate - fieldValuesStack.addArrangedSubview(valueTextView) + fieldValuesStackView.addArrangedSubview(valueTextView) } if accountUpdater == nil { diff --git a/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.xib b/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.xib index 516d540f..4982581b 100644 --- a/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.xib +++ b/Tusker/Views/Profile Header/ProfileHeaderTableViewCell.xib @@ -1,8 +1,7 @@ - - + - + @@ -161,7 +160,7 @@ - +