A 2016 photo of a Wells Fargo Bank branch in Woodbridge, Va. (Saul Loeb/AFP/Getty Images)

The city of Philadelphia sued Wells Fargo on Monday for allegedly discriminating against minority home buyers.

The complaint filed in a federal court in Pennsylvania alleges that Wells Fargo violated the Fair Housing Act of 1968 by “steering” minority borrowers into mortgages that were more expensive and riskier than those offered to white borrowers, according to court documents.

The lawsuit says that Wells Fargo is among the major banks with a “history of redlining” in Philadelphia, a practice traced back to the 1930s that involves denying credit to borrowers in certain communities because of their race or ethnicity.

The complaint says that between 2004 and 2014, African American borrowers were twice as likely to receive high-cost loans when compared to white borrowers with similar credit backgrounds. Latino borrowers were 1.7 times as likely to receive costly loans when compared to white borrowers, the lawsuit claims.

“The city’s unsubstantiated accusations against Wells Fargo do not reflect how we operate in Philadelphia and all of the communities we serve,” Wells Fargo spokesman Tom Goyda said in a statement. “Wells Fargo has been a part of the Philadelphia community for more than 140 years and we will vigorously defend our record as a fair and responsible lender.”

The filing comes as the bank is still recovering from a sales scandal in which bank employees opened millions of unauthorized accounts in customers’ names. The complaint draws parallels between the alleged predatory lending and the problematic sales targets by saying there was a lack of “internal controls” that could have prevented both issues.

Many borrowers were also rejected later when they applied for credit that would have allowed them to refinance those more expensive loans, according to the complaint. As a result, minority borrowers faced higher rates of foreclosure — a pattern that also hurt the city by leading to lower property taxes and more frequent incidents of vandalism and crime, the lawsuit claims.

Monday’s lawsuit comes just two weeks after the U.S. Supreme Court ruled that cities have standing to sue banks for predatory lending practices, on the grounds that the cities can also incur financial damages, such as reduced tax revenue.

In that case Miami sued Bank of America and Wells Fargo, arguing that discriminatory lending practices led to higher rates of default for minority borrowers. Miami, which was represented by the same lawyers handling the Philadelphia case, claimed that the banks in turn caused financial harm to the city by leading to lower property taxes and requiring the city to provide services to struggling borrowers.

While the Philadelphia investigation has been underway for more than a year, the city waited until after the Supreme Court ruling to ensure that it would have legal standing to sue, said Benjamin Field, deputy city solicitor for Philadelphia, in an interview.

News of the Philadelphia lawsuit against Wells Fargo was first reported by Reuters.