Skip to content

Commit

Permalink
Fix comments
Browse files Browse the repository at this point in the history
  • Loading branch information
MouazAlzahabi committed Aug 10, 2023
1 parent 2ca8be4 commit 342048d
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,10 @@ class KeySecurityOverviewViewController: LoadableViewController, UITableViewDele
}

func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let factor = sections[indexPath.section].items[indexPath.row]
switch sections[indexPath.section].section {
case .enabledFactors(_), .otherFactors(_):
if case let Section.Factor.factor(name, value, image, isDefault, selected) = sections[indexPath.section].items[indexPath.row] {
if case let Section.Factor.factor(name, value, image, isDefault, selected) = factor {
let cell = tableView.dequeueCell(SecurityFactorTableViewCell.self, for: indexPath)
cell.selectionStyle = .none
cell.set(name: name,
Expand All @@ -111,7 +112,7 @@ class KeySecurityOverviewViewController: LoadableViewController, UITableViewDele
return cell
}
case .info:
if case let Section.Info.info(text, image) = sections[indexPath.section].items[indexPath.row] {
if case let Section.Info.info(text, image) = factor {
let cell = tableView.dequeueCell(WarningTableViewCell.self, for: indexPath)
cell.selectionStyle = .none
cell.set(image: UIImage(named: image)?.withTintColor(.info, renderingMode: .alwaysOriginal),
Expand Down

0 comments on commit 342048d

Please sign in to comment.