Senate Majority Leader Mitch McConnell (R-Ky.).  (Albin Lohr-Jones/Pool via Bloomberg News)

Six days ago, it looked as though Betsy DeVos was going to be the first political casualty of the Trump administration. Two Republican senators — Susan Collins of Maine and Lisa Murkowski of Alaska — had just announced their opposition to DeVos's confirmation as education secretary.  All Democrats needed was one more Republican to oppose DeVos, and her nomination would fail.

But just after noon on Tuesday, DeVos's nomination was confirmed in a 51-50 vote —  a margin that necessitated a historic tiebreaking vote cast by Vice President Pence.

Vice President Pence cast his tie-breaking vote in the Senate to confirm President Trump's choice for education secretary, Betsy DeVos. (Reuters)

What happened over that period of time? Senate Majority Leader Mitch McConnell happened.

The Senate majority leader clearly had a plan to get DeVos confirmed from the start. The idea that Collins and Murkowski went rogue or that they would be the leading edge of a broader Republican revolt never materialized because McConnell (R-Ky.) had the situation under control from the beginning.

“He has an innate understanding of his conference, which allows him to get what he needs done without breaking every arm on every vote,” said Josh Holmes, a former McConnell chief of staff, about his former boss. “He does his homework and makes his asks with precision.”

Longtime congressional reporters affirmed Holmes's analysis of McConnell's behind-the-scene-savvy on the DeVos vote.

Looking back, it's hard to dismiss the idea that McConnell orchestrated the whole thing.  Consider:

1. Murkowski and Collins — both moderates sitting in rural states where a “no” vote on DeVos was smart politics — came out in opposition to her nomination within hours of one another.

2. McConnell's chief deputy, Sen. John Cornyn (Tex.), immediately promised that DeVos would be confirmed.

3. On-the-fence senators like Patrick J. Toomey of Pennsylvania and Deb Fischer of Nebraska quickly got off that fence, announcing they would support DeVos.

4.  There was zero chatter from Republican senators on the Sunday chat shows about the possibility that DeVos might not be confirmed.

McConnell knew he could afford to lose two Republican votes assuming that the vote to confirm Sen. Jeff Sessions (Ala.) as attorney general came after the DeVos vote.  And he signaled to Collins and Murkowski that they were absolutely fine to break with their conference on DeVos, knowing it would help them politically — and, of course, by helping them politically that he could rely on them for a vote he really needed in the future.

The drama over whether DeVos was going to be confirmed wasn't drama at all. Not really. It was the carefully laid plan of a master vote-counter who knew exactly how much he could give and gave it.