 extension PickerViewController: UIPickerViewDelegate {
 
   func pickerView(_ pickerView: UIPickerView, titleForRow row: Int, forComponent component: Int) -> String? {
-    return self.collection.items.first?[row].name
+    return sections.first?.rows[row].name
   }
 }

  }

  func pickerView(_ pickerView: UIPickerView, numberOfRowsInComponent component: Int) -> Int {
    return self.collection[component].countOfItems
  }
}


import UIKit

final class PickerViewController: RevertViewController {
  private let sections: [CountrySection] = RevertItems.capitalCities.newData()
}

// MARK: - UIPickerViewDataSource
