The Senate on Thursday voted along party lines to confirm Republican Rep. Jim Bridenstine James (Jim) Frederick BridenstineNASA publishes Artemis plan to land first woman, next man on moon NASA is in the market for moon rocks Overnight Defense: Trump hosts Israel, UAE, Bahrain for historic signing l Air Force reveals it secretly built and flew new fighter jet l Coronavirus creates delay in Pentagon research for alternative to 'forever chemicals' MORE (Okla.), President Trump Donald John TrumpOmar fires back at Trump over rally remarks: 'This is my country' Pelosi: Trump hurrying to fill SCOTUS seat so he can repeal ObamaCare Trump mocks Biden appearance, mask use ahead of first debate MORE’s choice to lead the National Aeronautics and Space Administration (NASA).

The 50-49 vote came after months of Democratic attempts to stop Bridenstine's confirmation and a day after a procedural vote that nearly failed.

The vote came after a dramatic nearly hourlong vote period on the Senate floor. Sen. Jeff Flake Jeffrey (Jeff) Lane FlakeJeff Flake: Republicans 'should hold the same position' on SCOTUS vacancy as 2016 Republican former Michigan governor says he's voting for Biden Maybe they just don't like cowboys: The president is successful, some just don't like his style MORE (R-Ariz.) cast the final "yes" vote after holding out for about 15 minutes longer than his fellow Senators.

ADVERTISEMENT

Flake was seen speaking to Senate leaders and their staff, including Majority Whip John Cornyn John CornynThe Hill's Campaign Report: GOP set to ask SCOTUS to limit mail-in voting Liberal super PAC launches ads targeting vulnerable GOP senators over SCOTUS fight Senate GOP faces pivotal moment on pick for Supreme Court MORE (R-Texas). It wasn’t immediately clear why Flake waited so long.

He similarly withheld his vote Wednesday on a procedural motion to move forward on Bridenstine’s confirmation. Cornyn said at the time that Flake wanted more time to meet with CIA Director Mike Pompeo Michael (Mike) Richard PompeoOvernight Defense: Pentagon redirects pandemic funding to defense contractors | US planning for full Afghanistan withdrawal by May | Anti-Trump GOP group puts ads in military papers Overnight Defense: House Democrats unveil stopgap spending measure to GOP opposition | Bill includes .6B for new subs | Trump issues Iran sanctions after world shrugs at US action at UN Navalny calls on Russia to return clothes he was wearing when he fell ill MORE, Trump’s nominee for secretary of State, before the Senate moved forward on that nomination.

All Republicans voted to confirm and all Democrats and independents voted against.

Bridenstine, who has represented Tulsa, Okla., since 2013, is a former Navy pilot, and previously led the Tulsa Air and Space Museum & Planetarium.

He’ll be responsible for a 17,000-person agency whose far-reaching duties include space exploration, overseeing commercial space activities, studying aeronautics and researching the Earth’s atmosphere, among other tasks.

While Republicans hailed Bridenstine as a top-notch candidate to lead NASA, Democrats argued that he was unqualified for the high-profile scientific spot and too divisive of a politician. They also argued that his views, such as doubting climate change science and opposition to LGBT rights, ought to disqualify him.

A key vote for Bridenstine came from Sen. Marco Rubio Marco Antonio RubioOvernight Defense: Pentagon redirects pandemic funding to defense contractors | US planning for full Afghanistan withdrawal by May | Anti-Trump GOP group puts ads in military papers Democrats step up hardball tactics as Supreme Court fight heats up Press: Notorious RBG vs Notorious GOP MORE (R-Fla.).

Rubio, whose state hosts NASA’s primary space launch facility, had bemoaned the nomination of a “politician” to lead the agency instead of a scientist.

Bridenstine notably spoke in advertisements for Sen. Ted Cruz Rafael (Ted) Edward CruzTrump argues full Supreme Court needed to settle potential election disputes Press: Notorious RBG vs Notorious GOP The Hill's Morning Report - Sponsored by Facebook - Washington on edge amid SCOTUS vacancy MORE’s (R-Texas) 2016 presidential campaign, frequently criticizing Rubio as weak on security and immigration.

Rubio said earlier Thursday that though he still had misgivings about Bridenstine, the impending retirement of acting NASA Director Robert Lightfoot meant the organization needs a leader.

“I was not enthused about the nomination,” he said on the Senate floor. “Nothing personal about Mr. Bridenstine. NASA is an organization that needs to be led by a space professional.”

Lightfoot’s departure, Rubio said, “leaves us with the prospect of this incredible agency with a vacancy in its top job.”

Rubio’s GOP colleagues had no reservations about supporting Bridenstine.

“Claiming our rightful place in the stars will require an effort spanning many years and several presidential administrations,” Sen. Mike Lee Michael (Mike) Shumway LeeMcConnell shores up GOP support for coronavirus package McConnell tries to unify GOP Davis: The Hall of Shame for GOP senators who remain silent on Donald Trump MORE (R-Utah) said. “We can begin that undertaking today by confirming a leader with a remarkable record of service to our country, a vision for the American space program that is big, not small, and a genuine faith in his country that is as boundless as the heavens. That man is Jim Bridenstine.”

Democrats argued that Bridenstine is the wrong man for the job.

“Jim Bridenstine, the nominee that we are considering, served as a Navy pilot, and I thank him for his service. But that does not qualify him to run NASA,” said Sen. Brian Schatz Brian Emanuel SchatzCDC causes new storm by pulling coronavirus guidance Overnight Health Care: CDC pulls revised guidance on coronavirus | Government watchdog finds supply shortages are harming US response | As virus pummels US, Europe sees its own spike Video of Lindsey Graham arguing against nominating a Supreme Court justice in an election year goes viral MORE (D-Hawaii).

“Just because you know how to fly a plane does not mean that you have the skills and experience to lead the federal government's space agency,” he continued.

“James Bridenstine is a climate denier with no scientific background who has made a career out of ignoring science,” Schatz said.

NASA is one of the leading federal agencies responsible for studying climate change, including tracking temperature changes throughout history.

“I am deeply concerned about this nomination because it is further evidence of a much deeper problem. I am concerned this administration does not respect science, especially science in government institutions,” said Sen. Gary Peters Gary Charles PetersBiden's six best bets in 2016 Trump states GOP set to release controversial Biden report Democrats fear Russia interference could spoil bid to retake Senate MORE (D-Mich.). “NASA’s science and research needs a champion who understands and promotes the nuances of work being done by their team. In short, NASA needs an administrator who will be driven by science and not politics.”

The vote was also notable for the final vote cast.

Sen. Tammy Duckworth Ladda (Tammy) Tammy DuckworthMcConnell focuses on confirming judicial nominees with COVID-19 talks stalled Biden courts veterans amid fallout from Trump military controversies John Fogerty: 'Confounding' that Trump campaign played 'Fortunate Son' at rally MORE (D-Ill.) briefly returned from her maternity leave, with her baby in her arms, to cast a vote against Bridenstine. Senators applauded her when she came in, and a handful crowded around her to see the child.

Duckworth gave birth to her daughter, Maile, on April 9, becoming the first woman to give birth to a baby while in the Senate.

The Senate passed a resolution Wednesday evening to allow her to bring her baby onto the floor during votes.