The problem here is the author’s development process. There’s an “old” programmer adage in regard to version control: merge early, merge often. It addresses the author’s issue directly.
So yes, it’s not the code that’s bad. It the development process. Bad (ok, fine, inexperience) developer.