Improve code based on SwiftLint warning

pull/2697/head
Hwee-Boon Yar 4 years ago
parent 2b1615337b
commit 7f0c6f9b41
  1. 6
      AlphaWallet/Transfer/ViewControllers/SignatureConfirmationViewController.swift

@ -256,11 +256,11 @@ extension SignatureConfirmationViewController {
private func generateSubviews() {
stackView.removeAllArrangedSubviews()
var views: [UIView] = []
switch viewModel {
case .typedMessage(let viewModel):
for (sectionIndex, _) in viewModel.typedData.enumerated() {
for sectionIndex in viewModel.typedData.indices {
let header = TransactionConfirmationHeaderView(viewModel: viewModel.headerViewModel(section: sectionIndex))
header.delegate = self
header.enableTapAction(title: "Show")
@ -277,7 +277,7 @@ extension SignatureConfirmationViewController {
views.append(header)
case .eip712v3And4(viewModel: let viewModel):
for (sectionIndex, _) in viewModel.values.enumerated() {
for sectionIndex in viewModel.values.indices {
let header = TransactionConfirmationHeaderView(viewModel: viewModel.headerViewModel(section: sectionIndex))
header.delegate = self
header.enableTapAction(title: "Show")

Loading…
Cancel
Save