Fixed typo on line 641 of main.py: tags --> taglist
Fixed button generation for case when tocref has an unmatched toclabel