added validation