"Enabled templates"-setting and some cleaning up