As a young building inspector in 1992, Dominic Verdi worried about corruption within the city's Department of Licenses and Inspections, and pitched a plan to fix it.

On Wednesday, Verdi stood before a federal magistrate judge, charged with contributing to the very problem he once railed against.

A day after federal prosecutors accused the department's former deputy commissioner of extorting more than $1 million from bar and nightclub owners, Verdi, now 58, turned himself in and pleaded not guilty to the charges.

As he left court Tuesday, Verdi declined to address the allegations or his time at L&I.

But court records as well as interviews with former coworkers and lawyers suggest his 35-year career with the city regulatory agency was marked by similar contrasts.

Throughout the late 1990s, he earned a reputation as an aggressive enforcer of city building codes. By day, he staked out Home Depots while on the hunt for contractors working on unlicensed remodeling jobs. By night, he donned a bulletproof vest to accompany police on raids of crack houses and nuisance bars.

Yet, as federal prosecutors now describe it, by the time he became L&I's deputy commissioner in 2007, he routinely cut breaks for friends and patrons of Chappy's Beer, Butts & Bets, a South Philadelphia beer distributorship in which he held an ownership stake.

He left the department in 2011, after news of his involvement in a federal probe surfaced.

But according to the indictment unsealed Tuesday, he helped dozens of bar and nightclub owners deal with any heat they were getting from L&I - as long as they bought their beer at the right place.

"When I was there, he was a low-level building inspector," said Bennett Levin, who led L&I in the early 1990s. "I believe he was clean when he worked for me."

It was under Levin that Verdi first raised his concerns about graft within the department and requested a meeting with his boss to discuss them.

Recalling their conversation over sandwiches at the Famous 4th Street Deli, Levin said Verdi believed street-level building inspectors were more susceptible to graft because they had no clear path to advancement within the department.

"He said there was corruption because as a building inspector, there was no opportunity for promotions," Levin said. "As a result of that conversation, we changed the way building inspectors were treated."

Levin left the department in 1995. Verdi stayed on. Under new boss Edward J. McLaughlin, his career took off.

A former police inspector, McLaughlin brought a new attitude to L&I, urging closer cooperation with other authorities and use of law enforcement-style tactics.

He promoted Verdi and assigned him to work out of Police Headquarters as part of the city's Nuisance Task Force, a joint law enforcement-regulatory team that used city code violations to shut down problem bars, drug houses, and brothels.

Verdi, according to former coworkers, eagerly embraced the new responsibilities and frequently joined police on their raids.

He was present during one 2003 raid at a South Philadelphia club as officers arrested Gregory Quigley, then a young law clerk, for disorderly conduct - shouting obscenities at officers and attempting to block inspectors from seizing the bar's money.

Quigley's name would later surface in federal authorities' investigation - as a co-owner at Chappy's, and as a man who touted his relationship to Verdi.

But from early on, McLaughlin's approach - and Verdi's role in it - drew scrutiny from critics.

When McLaughlin was reappointed to his post in 2000, then-Mayor John F. Street's transition team, which included Levin, raised concerns over the department's use of force. They cited a number of lawsuits in which Verdi's tough tactics played a role.

"There was an overall lack of due process," said Joseph DiOrio, a lawyer who brought three such suits against Verdi and the city. "They were shutting businesses down for code violations without giving them due process or chance to address the problems."

Chris Maffucci and Selena Fitanides sued the city in 1996 after a run-in with Verdi over a former convent in South Philadelphia that the couple hoped to turn into a home.

According to their suit, Verdi showed up one Saturday morning in 1996, demanded entry to the site, and when they asked to see a warrant, threatened to bury them with code violations. He returned later with a civil search order and police backup to fulfill that vow.

Their dustup and the more than two dozen code violations Verdi filed against the couple eventually came before U.S. District Judge James McGirr Kelly. In an opinion written three years later on the couple's lawsuit, the judge said Verdi's behavior exhibited "a general disregard for the law, punctuated by false verification and repeated misrepresentations to courts."

He ordered the city to pay Maffucci $350,000 plus attorneys' fees.

"The $350,000 that the city paid . . . sounds like we made out fine," Maffucci said Wednesday in an e-mail from Boston, where the couple now live. "But we'd gladly trade it back to have not had that experience with Verdi and L&I."

Yet by the time Verdi was promoted to L&I's deputy commissioner in 2007, the aggressive inspector had developed a far different reputation among a certain circle of bar owners - at least, according to federal prosecutors.

According to his indictment, Verdi routinely cut breaks for loyal customers of his beer distributorship, warning some of impending task-force raids and clearing away red tape for others facing being shut down for failed inspections.

In one case detailed by prosecutors, Verdi personally showed up at Oasis Gentleman's Club in Southwest Philadelphia on the night in 2009 that its owner was implicated in a patron's beating death. He assured another of the club's owners that he would control the situation and step in to ensure the place stayed open, the indictment says.

But the manager of one South Philadelphia restaurant that prosecutors say received favors from Verdi says she never believed their relationship and her business at Chappy's to be part of a quid pro quo.

"I bought beer there and a number of other places," said the manager, who spoke on condition of anonymity for fear of reprisals to her business. "If I had known I was earning favors, maybe I would have shopped there more."

215-925-2649 @jeremyrroebuck