added added validation and searching