ios - Ambiguous reference to member '(_:numberOfRowsInSection:)' -


i'm trying get gists github , pop them in table view, here's entire code, gist class defined elsewhere:

var gists = [gist]()  override func viewdidappear(animated: bool) {     loadgists() }  func loadgists() {     githubapimanager.sharedinstance.fetchpublicgists() { result in         guard result.error == nil else {             print("error 1")             return         }          if let fetchedgists = result.value {             self.gists = fetchedgists         }         self.tableview.reloaddata()         //error here.      } }  func tableview(tableview: uitableview, numberofrowsinsection section: int) -> int {     return gists.count }  func tableview(tableview: uitableview, cellforrowatindexpath indexpath: nsindexpath) -> uitableviewcell {     let cell = tableview.dequeuereusablecellwithidentifier("cell")!      let gist = gists[indexpath.row]     cell.textlabel?.text = gist.description     cell.detailtextlabel?.text = gist.ownerlogin      return cell } 

so, problem didn't add outlet of table view view controller.swift. dragged table view .swift file create it.


Comments

Popular posts from this blog

scala - 'wrong top statement declaration' when using slick in IntelliJ -

c# - DevExpress.Wpf.Grid.InfiniteGridSizeException was unhandled -

PySide and Qt Properties: Connecting signals from Python to QML -