James Gunn's tweets - the ones which he was originally fired for - were pretty awful.
You can find them through a quick bit of searching online, but it's important to remember that they were awful. Now, did James Gunn deserved to be fired for them? If he'd made them 8 months ago - as in, the day he was fired - yes. Yes, he probably should have been fired for making them then.
But he didn't make them then. He made them nearly 10 years ago, when he was trying his best to be a provocateur and someone who wasn't afraid to make tasteless jokes in order to get a rise out of people. This is something that James Gunn immediately put his hands up to, admitted his fault and culpability, and accepted his fate when he was fired.
That he took this on the chin with dignity and admitted his wrongdoing should have been enough for the powers that be within Disney. There's a great line from a book that describes the difference between an error and a mistake. Anyone can make an error, it says, but it doesn't become a mistake until you refuse to correct it. James Gunn made an error 10 years ago with his tasteless jokes.
Disney made a mistake in firing him because James Gunn had corrected his own error by growing and developing as an artist and as a person.
That's the key point here; that if James Gunn hadn't made these comments the day he was fired and not a decade ago, we wouldn't be having this discussion. It should have never come to this. Leave aside the fact that the people who dug up these tweets are utterly despicable, were acting in bad faith, and doing it because Gunn was an outspoken critic of them, and it's still wrong what happened.
So the question remains, why'd it take 8 months for Disney to correct the mistake? Was it only when he signed on to direct 'Suicide Squad 2' that the situation changed? Are Disney that calculating about it? Maybe. No official statement has come from Disney regarding their decision, and James Gunn's own words on the matter lack any kind of acknowledgement of how poorly Disney handled all of this.
The truth is, most likely, that we'll never know the answer. It might have been all these things. It might have been none of them. It might have been something as benign as a change of heart in Alan Horn's thinking, as rumours suggest it was his decision alone that allowed it to happen, overruling Marvel Studios' head-honcho Kevin Feige in the process.
Whether the cast standing behind Gunn made an impact, whether the outcry of public support for Gunn made a difference, whether it was something as methodical as the possibility of him working for Disney's direct competitor - it's irrelevant at this stage, because the error has been corrected.
Even if it did takes 8 months.