EngrAhsanAli/PaginatedTableView
Assign this class to your UITableView and it will be equipped with pull to refresh as well as infinite scroll along with a callback where you don't have to worry about page number/size stuff. Thats why libraries exist :)
SwiftMIT