A Sonoma County judge has ruled that Petaluma must reimburse its wastewater fund as much as $2.1 million that it improperly used to pay for storm-drain maintenance over a three-year period.

An exact repayment figure hasn't been determined, but Petaluma City Attorney Eric Danly estimated it may be closer to $1 million once additional evidence is presented.

Bryant Moynihan, a former city councilman who routinely questions the way the city budgets its money, in particular its wastewater funds, said the full amount misspent is far larger — $6.1 million in all.

In a split ruling, Judge Gary Nadler determined last month that Petaluma had been incorrectly funding some storm-water management functions with money from ratepayers' bills, as Moynihan argued. But he also said some of the claims were too old to consider.

The sides will meet Thursday with Nadler to set an evidentiary hearing to determine exactly how much Petaluma should reimburse its wastewater fund.

Exactly where the money would come from is undetermined, Danly said, but it could be the city's general fund, which pays for most city functions including salaries and benefits.

Moynihan filed the lawsuit in January 2012. He argued that since 2004 the city wrongfully diverted $6.1 million from the wastewater fund, which comes from ratepayers' bills, and spent it some stormwater management, a general fund expenditure.

He wanted the city to repay the wastewater fund and pay his attorneys' fees.

The city has argued that diverting stormwater from the wastewater system provides at least an indirect benefit to the wastewater fund because diverted rainwater doesn't have to be treated at the city's sewer plant, thus saving taxpayers money.

But court rulings have said that if a benefit isn't tied directly to the fund, fees or taxes to pay for it must be approved by voters.

Last year, the city conceded some of its spending was improper.

Moynihan contends the spending violates a number of laws and creates an illegal utility tax.

Danly said it was important that Nadler determined that the way the city began calculating its sewer rates in late 2011 is legal.

Nadler also determined that the city's calculation of certain stormwater management expenses — called inflow and infiltration avoidance costs — are legitimately charged to the wastewater fund.

The judge said the city's wastewater rates were commensurate with the cost to provide service.

Danly said the city plans to present "refined" evidence that could reduce the amount the judge orders Petaluma to reimburse the wastewater fund to about $1 million, or about $300,000 for the three years the order covers.

Current sewer rates won't change as a result of the ruling, Danly said.

Moynihan said the ruling was a victory for ratepayers, although he called for more.

"If the Petaluma City Council and administration has integrity and ethics, they would return the full $6.1 million they have taken from the sewer enterprise fund," he said. "The City Council will have wasted hundreds of thousands of dollars in legal costs in a foolish attempt to defend their illegal activities. Only the lawyers are getting rich."

(You can reach Staff Writer Lori A. Carter at 762-7297 or lori.carter@pressdemocrat.com.)