The New York AG announces a lawsuit against Wells Fargo and a settlement with Bank of America over alleged violations of the national mortgage settlement.

NEW YORK (TheStreet) -- New York Attorney General Eric Schneiderman announced Wednesday that he is suing Wells Fargo (WFC) for its alleged failure to adhere to the terms of the $25 billion national mortgage settlement.

He also said he was dropping a lawsuit against Bank of America (BAC) over similar complaints, with the bank agreeing to improve its practices.

Shares of Wells Fargo were down 1% in morning trading at $41.06. Shares of Bank of America were trading flat to slightly lower at $13.89.

Schneiderman said in May that he intended to sue the two banks for failing to adhere to servicing standards established by the mortgage settlement in early 2012 to help struggling borrowers. Under the settlement, the nation's five largest servicers - Bank of America, Wells Fargo, JPMorgan Chase (JPM), Citigroup (C) and Ally Financial agreed to provide billions of dollars in relief through refinancing, loan modifications, principal reductions and short sales, following allegations of illegal foreclosure proceedings.

The settlement outlined more than 300 servicing standards that required the banks to respond to borrowers in a timely manner and make it easier for homeowners seeking relief.

While the banks have been working toward meeting their relief targets under the agreement, the settlement monitor Joe Smith reported earlier this year that the volume of consumer complaints has increased, with many borrowers citing confusion over modification process and the lack of timely responses from banks.

Those violations increased the likelihood that distressed borrowers would default because the longer modifications were delayed the deeper they fell behind their payments, ultimately pushing them into foreclosure.