Added validation to create template