In a situation where there is a difficulty of that sort, the immigration officer would be considering both sides of the story, would not just be listening to one side. The officer would be very open to hearing from both sides what the situation is and to evaluating it on a case-by-case basis.
The guidelines for the officers are very extensive and are publicly available. They go into the sorts of things that the officers should be taking into consideration when they're making a determination about this.