UIRefreshControl does not work correctly
This works for me on iOS 11:
override func viewDidLoad() {
self.tableView.refreshControl = refreshControl
self.tableView.addSubview(refreshControl)
}
Also, you don't need to explicitly tell the refresh control to begin refreshing, so this is enough:
func refresh(_ sender: Any) {
Metric.sendEvent("RefreshFeed")
self.getFeeds(self.user.id)
}
Also make sure that in the callback for VNetwork.getFeeds(userId) { feeds in
you are on the main thread.