more the logic of upload/update files more clear