McFadden wasn't badly treated. One of the producers - Hurley - fancied her and when she rebuffed him he was...well, not very nice and eventually convinced Gene Roddenberry they needed a new doctor and McFadden should go. Berman was not happy with the decision, but Roddenberry overruled.
Fast forward a year: Hurley's on his way out, Roddenberry has very much taken a back seat, and Berman has the chance to either bring a third doctor in three years in, or ask McFadden to come back.
I understand that Berman got on well with McFadden and so the answer was an obvious one.