some refactoring of user templates made