fixing bugs for the new templates done