Too often partisan gridlock gets in the way of good lawmaking in Washington. So it was encouraging last week when the U.S. Senate broke through an impasse to get two things done — adopting an important bill to fight human trafficking and confirming a new U.S. attorney general.

With a logjam-busting assist from Minnesota Sen. Amy Klobuchar, a smart compromise helped get the Senate back to work.

Senators approved a measure that will direct more resources to federal and local law enforcement agencies to combat sex trafficking. Klobuchar is also recommending an amendment to ensure that those exploited by traffickers are treated as victims, not criminals.

Authored by Texas Republican Sen. John Cornyn and co-sponsored by Klobuchar, the trafficking measure originally had broad bipartisan support. But the bill hit a wall last month when Democrats were alerted to a GOP provision that prohibited money collected for trafficking victims from being used to fund abortions or other emergency contraception.

Republicans argued that the ban simply followed the Hyde Amendment, an existing law that bans federal funding for abortions. Democrats called it an expansion of Hyde, demanded that the provision be removed and blocked the Senate vote. And although the attorney general confirmation was unrelated, GOP senators refused to vote on it.

The Senate then went on break, but Klobuchar called Cornyn to suggest a compromise: Create two pools of money for victims of human trafficking and apply anti-abortion rules to only one of them. That change was added, and the Senate passed the bill. The next day, nominee Loretta Lynch was confirmed as the new U.S. attorney general.

This is the way Congress should conduct the people’s business — with compromise trumping ideology.