correct header leaves, regen toc