added validation for name length