jakemarsh / JMStaticContentTableViewController

A subclass-able way to cleanly and neatly implement a table view controller much like those in Settings.app, with nice-looking fields to collect or display information, all using a simple and convienent block-based syntax.

Home Page:http://deallocatedobjects.com/posts/create-static-content-screens-with-jmstaticcontenttableviewcontroller

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`-removeAllSections` leaves the tableview in a bad state

jbrennan opened this issue · comments

Calling -removeAllSections doesn't seem to actually remove the sections from the tableview itself, and so adding sections or touching the tableview causes the app to crash from a really nasty exception.

My current work around is to call [self.tableview reloadData] immediately after removing all sections. I'm not sure if this is the best possible solution but it seems to work for me.

Good catch, that method name could be much better. This is how I work with it in my JMStaticContentTableViewController subclasses. But it probably should call reloadData internally.