Ok, this is page one in this page group.
There is a bug. When looping is true (and it is, but only for this first page--another possible flaw) and if the Contents title is not the first item on the Table of Contents page, and if there are other things on the TOC page after the actual list, then things get screwed up. Note that the Previous: link below should point to the last page. Click Next.