Giffords
Former U.S. Rep. Gabrielle Giffords delivers her opening remarks while seated next to her husband, former U.S. Navy Captain Mark Kelly, during a hearing held by the Senate Judiciary committee about guns and violence in 2013. Giffords represented the 2nd Congressional District, which Republican Martha McSally won Wednesday. Reuters

The 2014 midterm elections are officially over. At about noon Thursday, the last unfinished Congressional race finished in a victory for Republican Martha McSally, who beat out Democratic Rep. Ron Barber by 167 votes to represent Arizona's 2nd Congressional District in Tucson.

McSally will take over the the area represented by Democrat Rep. Gabrielle Giffords from 2007 to 2012, when she resigned from the House of Representatives following an assassination attempt that left her severely injured. Giffords' aide Barber, who was among the 13 people injured in the shooting, took over her district, Politico reported.

Results from the midterm elections Nov. 4 put McSally 161 votes ahead of Barber, but that didn't leave a wide enough margin to declare an definitive victory. A few weeks later, a federal judge denied Barber's request to include 133 extra ballots that had been disqualified for various reasons, the Associated Press reported. The recount ensued regardless, and Wednesday Maricopa County Superior Court judge Katherine Cooper announced the official tally.

McSally, now retired from the Air Force, was the first American woman to fly in combat and the first woman to lead a fighter squadron. Barber beat her once before in the 2nd Congressional District, but McSally took the seat Wednesday.

"After a long, hard-fought campaign, today we were declared the official winner for our race to represent Southern Arizona in Congress," she wrote on her Facebook page. "Now, it’s time to move forward as one community to make sure Southern Arizonans have the strong representation they deserve. My focus will be on the priorities I heard from you throughout the campaign: provide better economy [sic] opportunity for our families and keep our country and communities safe."

With McSally, the Republican Party gains control of 247 seats in the House of Representatives -- a majority over the 188 Democrats.