added validation is file already exists