Iowa Senator Chuck Grassley says he’s distressed for several reasons over the Obama administration’s handling of a surprise prisoner swap to get a U.S. soldier back from the Taliban after five years in captivity.

Grassley, a Republican, says there’s a law in place that mandates no prisoner is to be released from the detention camp at Guantanamo without giving Congress 30 days notice. “The president takes an oath to uphold the laws, in fact, he signed that very law and Congress was not notified,” Grassley says. “A law was broken. I’m disappointed. I expected elected officials that take an oath to uphold the law to uphold the law.”

Critics say the administration chose to ignore that law because White House officials feared Congress would reject the proposed prisoner swap. Five Taliban terrorists were released in the exchange for Army Sergeant Bowe Bergdahl.

Grassley says the exchange was a mistake, especially in light of last week’s announcement that the U.S. will pull the last American troops out of Afghanistan by the end of 2016. “The release of these people, I think it’s going to be bad because in a year, they’ll be back on the battlefield and their goal is to kill Americans,” Grassley says. “They’ve already shown that. That’s why they were in Guantanamo in the first place. Can they change their mind? I doubt if they can.”

It was also a grave error, Grassley says, for the U.S. to have made a deal with the Taliban to secure Bergdahl’s release. Grassley says, “It might encourage other terrorist organizations to take Americans as prisoners so that they can trade them back for something that they want.” The circumstances are still unclear about how Bergdahl was captured, and some are calling him a deserter as the then-23-year-old allegedly walked off post without authorization.

Grassley notes several Americans died trying unsuccessfully to find and free the missing soldier.