Fix getTemplate() issue which caused an undefined variable to be called.