Fix bug in toc generation (using :custom-id, instead of :CUSTOM_ID).