Fix multiple braces in the templates after abstraction