That's kinda part of the job, to resolve conflicts, ideal is that if you are in a team, your team members do not edit the same files as you but if that happens you need to resolve the conflicts if any.
There are several tools to make this a little bit easier