If nothing else comes of it, the latest round of Pakistani aggression against India served as yet another signal to the U.S. that the time has come to cut its losses and walk away from Afghanistan.

On February 14, a Pakistani terrorist from Jaish-e-Mohammad terrorist organization, infiatrated the Indian side of the disputed Jammu and Kashmir province and murdered more than forty Indian paramilitary forces in a suicide bombing.

On February 26, the Indian Air Force bombed Jaish-e-Mohammad’s largest base in Pakistan. According to the Times of India, the base was located at Balakot, around 80 km. from the border with Indian controlled Jammu and Kashmir. In the course of the air strike, a “very high number” of terrorists, trainers and senior commanders were killed.

On Wednesday, Pakistani Prime Minister Imran Khan convened Pakistan’s top decision making body for nuclear issues. By convening the National Command Authority, Khan signaled that he was maintaining Pakistan’s military doctrine, which views nuclear war as a first strike option in all military confrontations with India. Also Wednesday, Pakistan retaliated against India’s counter-terror strike by bombing Indian military installations in Jammu and Kashmir. The bombing precipitated an aerial dogfight, and one Indian pilot who was downed alive over Pakistan was taken prisoner.

On Thursday, Khan told the Pakistani parliament that the government would return the pilot to India. And the latest round of Pakistani aggression and Indian retaliation seemed to have been resolved.

According to Asia Times, this week’s tensions were calmed by two primary forces, operating in tandem. The U.S. and Saudi Arabia convinced both the Indians and the Pakistanis to stand down. Notably, the efforts were successful not because both sides were able to claim victory, but because both the Saudis and the Americans gave full backing to India.

This is notable because for decades, both the U.S. and Saudi Arabia have been key allies and sponsors of Pakistan. The fact that this time both governments chose to stand entirely on India’s side and join Indian Prime Minister Narendra Modi in demanding that Pakistan take action against the terror groups that operate in its territory signaled to Pakistan that it had nothing to gain from continuing to raise hostilities. And so, it stood down.

As the debate in the U.S. ensues over whether to keep U.S. forces in Afghanistan; remove them in the framework of a deal with the Taliban; or just walk away, the latest round of hostilities between India and Pakistan signals strongly that the U.S.’s best option in Afghanistan is to walk away with no agreement.

For the past eighteen years, Pakistan, with its outlet to the sea, has served as the logistical base and supply line for U.S. forces operating in Afghanistan. If Pakistan had not permitted the U.S. to use its territory for this purpose, the U.S. would have been hard pressed to retain a long-term presence in landlocked Afghanistan. Indeed, in the absence of a Pakistani harbor for its supplies, the U.S. might have sufficed with goals far more limited than the Bush administration’s grandiose vision of transforming Afghanistan into a liberal democracy.

Whatever the case, Pakistan’s willingness to permit U.S. forces to ferry their equipment through its territory didn’t make it America’s ally in the war in Afghanistan. Far from it.

More than any other actor, Pakistan has arguably blocked any chance of a sustained U.S. victory in Afghanistan. While Pakistan has served as the U.S.’s logistical base, through its all-powerful Inter Service Intelligence (ISI) agency, Pakistan has also served as the Taliban’s primary sponsor as well as the primary sponsor of the Haqqani network, which is actively engaged in killing U.S. forces in Afghanistan.

Pakistan’s latest round of aggression with India is a reminder that just as Jaish-e-Mohammed and its jihadist rival Lashkar-e-Taiba are both run by the ISI, so the Taliban is ISI’s client.

For 18 years, successive administrations were at a loss for how to handle Pakistan. Recognizing that Pakistan was acting treacherously, administrations have sanctioned Islamabad, but never too harshly, because the U.S. felt it needed the Pakistanis. The thought, never entirely rational, was, that Pakistan was necessary to enable the U.S. to fight against Pakistani proxies in Afghanistan. Aside from that, the U.S. has been unwilling to walk away from Pakistan due to concern that China may replace America as the terror-sponsoring, nuclear-armed state’s primary superpower sponsor.

Regarding China, however, even as this concern informed U.S. decisionmakers, Pakistan expanded its strategic and political ties with China. In 2016, 63 percent of Pakistan’s foreign military assistance was Chinese. That year, arms exports to Pakistan constituted 35 percent of China’s total arms exports. So continued U.S. support for Pakistan didn’t make Islamabad avoid expanding their ties with China.

President Donald Trump signaled an end to this policy of turning a blind eye to Pakistani aggression last January. He tweeted, “The United States has foolishly given Pakistan more than 33 billion dollars in aid over the last 15 years, and they have given us nothing but lies and deceit, thinking of our leaders as fools. They give safe haven to the terrorists we hunt in Afghanistan with little help. No more!”

Weeks later, the U.S. cut $300 million from its military aid to Pakistan and signaled that all $2 billion in annual military assistance was in question.

Despite wails of protest from the Pentagon and Obama administration alumni, the administration suspended Pakistani officers from participating in the International Military Education and Training program which trains foreign military officers in U.S. military academies. The move was eminently sensible. Consider: the current director-general of Pakistan’s ISI, Lt. General Naveed Mukhta,r graduated from the U.S. Army’s War College at Carlisle, PA. Mukhtar’s American training clearly made no impact on his support for America’s enemies.

While curtailing U.S. support for Pakistan, the Trump administration has been working steadily to solidify a strategic alliance with India. Most significantly, last September, Secretary of State Mike Pompeo and then-Secretary of Defense James Mattis met with their Indian counterparts in New Delhi and signed an agreement that increased the interoperability of the U.S. and Indian armed forces, paving the way for Indian purchase of U.S. military technology that had been out of bounds until then.

That brings us to Afghanistan. The current U.S. policy is to leave after finalizing an agreement with the Taliban and other stakeholders through ongoing talks in Geneva. The talks are reportedly leading to an outcome that will see the Pakistan controlled-Taliban return to power in Afghanistan supported by Turkey on the one hand, and Iran on the other. This outcome, which may be inevitable in light of the balance of forces on the ground, is not one that redounds to the U.S.’s benefit.

Given that the outcome of the talks will not be a good one for America, the U.S. has no interest in being a party to such an agreement. The U.S. would be better off not signing any deal and walking away, rather than acquiescing to a settlement that isn’t in its interest. By walking away with no agreement, the U.S. would reserve its right to attack enemy targets, as it deems necessary, in the future.

Pakistan’s policy of using terrorism and nuclear brinksmanship to force India to accept its belligerence, like its policy of sponsoring the Taliban and other groups attacking U.S. forces in Afghanistan even while serving as the logistical base for U.S. operations, shows that it is well nigh time for the U.S. to follow through on Trump’s campaign policy of walking away from Afghanistan.

Just as there is nothing to be gained by taking a neutral stance between India and Pakistan, so there is no point in permitting Pakistan to play the U.S. for a fool in Afghanistan.

There are downsides to walking away from Afghanistan and Pakistan, but they are far smaller than the price the U.S. pays by funding the wars Pakistan wages against it.

Caroline Glick is a world-renowned journalist and commentator on the Middle East and U.S. foreign policy, and the author of The Israeli Solution: A One-State Plan for Peace in the Middle East. She is running for Israel’s Knesset as a member of the Yamin Hahadash (New Right) party in Israel’s parliamentary elections, scheduled for April 9. Read more at www.CarolineGlick.com.