I don’t think it’s only that. I don’t recall DJT ever promoting ivermectin, and they’ve tried to suppress it, too.
They dissed Ivermectin because it was offered as an alternative to the vaccines. Since the perception was that only conservatives, Christians, and Trump supporters opposed the vaccines, they doubled-down on opposing any alternatives to them. The opposition to Ivermectin was thus very political even though it did not directly involve Trump, who continues to support the vaccines, but not the mandates.