Donald Trump sold the Miss Universe Organization to WME/IMG, completing a split with the beauty- pageant group that began after his controversial remarks about Mexican immigrants.

Trump sold the organization just three days after buying it back from partner NBCUniversal, which cut ties after he said Mexicans bring drugs and crime to the U.S., calling them “rapists” during a speech announcing his campaign as a Republican presidential candidate in June.

No terms were disclosed. In a statement, Trump said the pageants "are now in the hands of a great company that will shepherd them to even greater levels of success.”

On Friday, Trump wrote on Twitter that he acquired the stake owned by Comcast Corp.’s NBCUniversal in the Miss Universe Organization, becoming the sole owner. “Stay tuned,” he wrote. Trump was in talks to sell the entire company to Ari Emanuel and Patrick Whitesell’s WME/IMG, people with knowledge of the matter said at the time.

In June, NBC said the annual Miss USA and Miss Universe Pageants would no longer air on the network and that it was ending its business relationship with Trump, citing “recent derogatory statements” about immigrants during a speech announcing his campaign as a Republican presidential candidate.

In a talent agency merger, IMG was acquired by William Morris Endeavor Entertainment LLC and Silver Lake Management in 2014.