Fixes template problems