Less than 24 hours after the U.S. Navy sailors were captured, they were released Wednesday morning. It’s being applauded as proof that relations are softening since both countries agreed on a landmark nuclear accord in July.

The guard captured the sailors Tuesday for allegedly “trespassing” in the country’s Persian Gulf waters.

Riverine boats that apparently had mechanical trouble and drifted into Iranian waters.

In a speech at the National Defense University, Secretary of State John Kerry said on Wednesday in a statement that the sailors appear to have been “well taken care of, provided with blankets and food and assisted with their return to the fleet.” Once U.S naval forces had them, the sailors were flown to a military facility in Qatar, debriefed, and given medical exams.

“These are always situations as everybody here knows which have an ability, if not properly guided, to get out of control,” Kerry said. “I’m appreciative for the quick and appropriate response of the Iranian authorities.”

Iran has captured Western military forces before, and for a much longer detention. A June 2004 incident involving six Royal Marines and two naval personnel who’d also been accused of crossing into Iranian waters only ended after the eight captors were freed three days later. In March 2007, the country held 15 British servicemen for 13 days after seizing them in the Shatt al-Arab waterway separating its boarder from Iraq, in a similar dispute over territory as the one triggering Tuesday’s incident. Five more Britons were held for a week in 2009 when the country delayed their racing yacht.

Tuesday’s drama and Iran’s demand for an apology had everyone on edge with the terms of the nuclear accord between the United States and Iran (and five other countries) scheduled to go into effect in a matter of days.

Under the terms of that agreement, the United States will unfreeze roughly $100 billion in Iranian assets while Iran ships 98 percent of its nuclear fuel out of the country, disables centrifuges, and takes a plutonium reactor offline.

“I think we can all imagine how a similar situation might have played out three or four years ago,” Kerry said about this quickly resolved situation. “In fact, it is clear that today this kind of issue was able to be peacefully resolved and efficiently resolved and that is a testament to the critical role that diplomacy plays in keeping our country safe, secure and strong.”