On Twitter on Tuesday, Roseanne Barr wrote that if “muslim brotherhood & planet of the apes had a baby = vj.” The message referred to President Barack Obama’s former senior adviser Valerie Jarrett, and in it Ms. Barr traded on age-old racist ideas about black people and primates. Then she shared some incorrect nonsense about Chelsea Clinton marrying into the Soros family.

It was the kind of thing Roseanne Barr has been doing online for years. This time, however, the backlash was immediate and vigorous. Ms. Barr apologized for her “joke” that wasn’t really a joke and said she was leaving Twitter as if Twitter were responsible for her racist behavior. That apology was not enough. ICM Partners, her agents, stopped representing her. The comedian Wanda Sykes, who was a consulting producer on the reboot of “Roseanne,” announced that she was quitting the show. Within a matter of hours, ABC canceled the new “Roseanne” and the original show’s reruns were pulled from TV Land, CMT and the Paramount Network.

For once, a major network did the right thing. But before it did the right thing, it did the wrong thing. It is not new information that Roseanne Barr makes racist, Islamophobic and misogynistic statements and is happy to peddle all manner of dangerous conspiracy theories. ABC knew this when it greenlighted the “Roseanne” reboot. ABC knew this when it quickly renewed the reboot for a second season, buoyed, no doubt, by the show’s strong ratings.

The cast, the writers and the producers knew what Ms. Barr stood for when they agreed to work on the show. Everyone involved made a decision to support the show despite its co-creator’s racism. They decided that their career ambitions, or desire to return to network television, or financial interests would best be served by looking the other way. It was only when Ms. Barr became an immediate liability that everyone involved finally looked at her racism and dealt with it directly.