Ukraine does suffer from corruption, but it’s by no means the worst offender among the recipients of American largesse. The research group Security Assistance Monitor noted in a report last fall that some two-thirds of the countries receiving U.S. counterterrorism aid, or 24 of 36 countries examined, “posed serious corruption risks.” In Ukraine’s case, the Obama White House hesitated to provide military aid—and avoided providing lethal aid altogether—for other reasons, fearing that doing so would provoke Russia and worsen the conflict.

Read: Volodymyr Zelensky plays himself

After Barack Obama left, Trump announced, and Congress approved, a plan to provide anti-tank missiles as well, something both military and diplomatic officials had recommended. Joseph Dunford, then the chairman of the Joint Chiefs of Staff, said in congressional testimony in the fall of 2017 that “Ukraine needed additional capabilities to protect their sovereignty” from Russia, which was supporting an insurgency in the eastern half of the country and had already seized the Crimean Peninsula. To the extent corruption was a concern at the time, it did not take precedence over the determination to try to stop Russian tanks.

The Pentagon specifically said Ukraine was making progress tackling corruption in a letter to Congress this spring, two months before Trump suspended aid and then raised the corruption issue in the phone call with Ukraine’s president, during which he asked for an investigation into Joe Biden’s son. The letter from the Defense Department, which NPR first reported, certified that “the government of Ukraine has taken substantial actions to make defense institutional reforms for the purposes of decreasing corruption,” among other things.

Read: What happened in Ukraine?

But other countries’ experiences have demonstrated how aid itself can fuel corruption, even indirectly by freeing up more of the host government’s resources to distribute bribes. Or it can create perverse incentives. A weak government in a country getting massive amounts of military aid has reason to fear the development of a strong and professional military; see: Egypt’s Mohamed Morsi.

And security assistance can simply fail entirely—especially when corruption is endemic. This was the case in Iraq in 2014, which Transparency International has called “one of the most spectacular defeats of the 21st century [in which] 25,000 Iraqi soldiers and police were dispersed by just 1,300 ISIS fighters in the northern Iraqi city of Mosul.” One key factor: Then–Prime Minister Nouri al-Maliki prized loyalty over competence in the promotion of senior officers, some of whom preferred stealing public funds to training a competent fighting force.

So it stands to reason that the U.S. should be able to withhold military aid—either to try to force better behavior, or simply to stop wasting taxpayer money on something that’s not working. It’s not especially rare—historically, presidents and lawmakers have done this for all kinds of reasons. In 1982, President Ronald Reagan did it to Israel, stopping the sale of cluster bombs to the country for six years after Congress found Israel had used them against civilians in Lebanon. The George W. Bush administration once suspended military aid to 35 countries simultaneously when they refused to guarantee U.S. immunity in potential cases at the recently formed International Criminal Court. (Much of this money has since been reinstated, particularly for NATO and major non-NATO allies.) There’s a law that bans assistance to human-rights abusers, though it applies to military units, not to entire countries. It was this law, for instance, that Trump’s State Department invoked in 2017 when declaring Burmese units involved in abuses against Rohingya Muslims to be ineligible for military aid.