Lawmakers in Albany voted Tuesday to keep Barbara Underwood, the former state solicitor general and current acting attorney general, as the interim head of the Attorney General's Office until a new attorney general is elected later this year.

In a statement, Underwood praised the “talent and dedication of the people” that make up the Attorney General's Office. She called the decision by state legislators a “tremendous honor” for the “most important job I have ever had.”

“In the past few weeks, they have once again demonstrated their professionalism by pursuing the vital work of the people—rooting out fraud, fighting the opioid epidemic, protecting the vulnerable, and defending and enforcing the laws of our state,” she said. “At this moment, when so many New Yorkers are fearful of the effects of overreaching and discriminatory federal policies on them and their families, the role of the New York Attorney General's Office is more important than ever.”

In a joint session of the state Assembly and Senate, 190 of the 213 total state lawmakers, the vast majority of which were Democrats from the two chambers, voted to keep Underwood as the head of the office until the next attorney general was elected. While Underwood's selection was propelled by Democrats, she also earned the praise of Sen. John Flanagan, the Republican majority leader.

“She's competent, she's capable, she has a stellar record, and she will be a terrific interim attorney general,” Flanagan said ahead of his vote in her favor.

The one recorded “no” vote came from Assemblyman Charles Barron, a Brooklyn Democrat, who said he opposed her nomination over the lack of transparency in the selection process.

Earlier in the day, Assemblyman Joseph Lentol, who headed the committee that vetted the potential candidates for the job, said the move was occurring under “unique circumstances,” as legislators attempt to “fill a vacancy so close to an election.”

“This is an effort not only to have exercised our constitutional responsibility, but also to pick somebody who has the best chance of preserving the continuity of the office of attorney general until the election,” Lentol said.

Underwood was thrust into the role after Eric Schneiderman announced his resignation just hours after a May 7 article in The New Yorker went online, in which multiple women claimed they were choked, slapped and demeaned by Schneiderman during their prior relationships with him.

The installation of Underwood as acting attorney general made her the first female attorney general in state history. As part of the political process of picking an interim replacement of Schneiderman, Underwood added her name to a list of 12 other candidates who agreed to the vetting process laid out by state lawmakers. She made it clear early on she had no intention of seeking the position through electoral means come November.

“I am not a politician,” she said during her interview on May 15.

While affirming her disinterest in politics, Underwood told lawmakers she did believe she was the right person to continue to lead the office ahead of elections for a new attorney general this fall.

“I believe that, at this critical time, the attorney general must be a stabilizing and strong voice for the rule of law,” she said. “I assure you that I can be that voice.”

Underwood's selection was not a given in the raw political dynamics of the state Capitol, even as her legal acumen and experience practicing at every level of government led some to declare few were better suited to stay in the job.

New York state law provides the state Legislature the power to name an interim attorney general by a simple majority of the total number of assembly members and senators. Given the lopsided Democratic majority in the Assembly, the chamber's speaker, Assemblyman Carl Heastie, was positioned to control the political dynamics around the decision.

Many Albany political observers saw the process as more geared to serve the political needs of elected officials and party leaders than to select the person who was best situated to steer the office through a chaotic period.

Early rumblings in the press about supposed plans by Heastie and his allies to install New York City Public Advocate Letitia James as attorney general appeared to confirm that pattern. An attorney and former member of the New York City Council, James' selection would have allowed for political allies of Heastie to try to move into more favorable elected positions, by creating a sudden vacancy in the public advocate's office, while satisfying legitimate desires for a woman of color to perform a job previously occupied only by white men.

Even as the behind-the-scenes negotiations in Albany were playing out, an aggressive push in the media helped to turn the tide for Underwood. Papers across the state ran editorials in support of her to remain as the interim attorney general. Numerous laudatory articles touting her long and impressive history appeared in newspapers and magazines, including being featured in a Cosmopolitan magazine piece titled “Meet the Women Taking Over for Eric Schneiderman.”

Numerous prominent figures stepped forward to support Underwood staying on, including former Manhattan U.S. Attorney Preet Bharara, whose name had also been floated for the position, and the state Senate majority leader Flanagan, R-Suffolk. Even Gov. Andrew Cuomo said he agreed with Underwood's own estimate of her abilities to do the job, calling her “a person of extraordinary talent.”

This much has never been in doubt.

A native of Evansville, Indiana, and a graduate of Georgetown University Law Center, Underwood launched her early career with two distinguished clerkships, with Chief Judge David L. Bazelon of the U.S. Court of Appeals for the D.C. Circuit and Justice Thurgood Marshall of the U.S. Supreme Court.

She's served in the offices of three different district attorneys in the city—former DAs Elizabeth Holtzman and Robert Morgenthau, and Queens DA Richard Brown—before joining the Brooklyn U.S. Attorney's Office in the mid-1990s.

Underwood became first principal deputy solicitor general of the United States in 1998, and, beginning in 2001, acting solicitor general. She was the first woman to operate in that position. In 2007, she was named New York's solicitor general by then-Attorney General Cuomo, where she has remained since.

Over the years, Underwood has argued some 20 cases before the U.S. Supreme Court; taught at a number of law schools, including Yale, New York University School of Law, and Brooklyn Law School; and served as chairwoman of the New York City Bar Association's executive committee.

Underwood's selection as interim attorney general means a person who has been widely praised and is deeply admired among the staff in the Attorney General's Office will remain at the helm while the political process takes its course. Public Advocate James has officially declared as a candidate, and is quickly locking up support from Democratic elected officials and labor groups, making her the early front-runner ahead of the party's nominating convention this week.

A number of others are considering challenging her in the September primary, including Fordham University School of Law associate professor Zephyr Teachout, who ran against Cuomo for the governorship four years ago. Republicans, at their own parallel convention, are set to nominate their own candidate later this week as well.