Fixed regexp bug in toc_activate