fixing a couple of template and syntax issues identified by @galstrom21