I wish it were that simple. There must be some way around it.
There are, but they're complex and mostly in place to deal with the issue of what happens when a candidate dies. If the GOP fires Trump as the candidate and Trump says that he's still the candidate because they can't fire him, then there aren't a whole lot of clear resolutions about what happens and it'll mostly be up to individual judges. That's all somewhat moot because the screaming craziness would have a large swath of the GOP stay home in protest no matter what the result is and Clinton would cruise to victory.