Chuck Ross and Matthew Foldi take a closer look at Democrats’ go-to election attorney, Marc Elias.

Democratic election lawyer Marc Elias has long decried the evils of gerrymandering. Now, he’s getting rich off it.

Democratic and progressive groups paid Elias’s firm more than $1 million in the most recent quarter, according to Federal Election Commission records released this week. One of Elias’s biggest clients, the Democratic Congressional Campaign Committee, is leading efforts to redraw congressional districts in New York and Maryland. With polls indicating Democratic losses in November, the controversial gerrymander scheme is seen as the party’s best hope of maintaining majority control of Congress.

The effort opens both parties up to allegations of hypocrisy. Rep. Sean Patrick Maloney (D., N.Y.), the chairman of the DCCC who worked with Elias to redraw New York’s maps, accused  Republicans last year of using gerrymandering to win control of the House. Elias has repeatedly accused Republicans of partisan gerrymandering. He recently sued to block North Carolina and Ohio from adopting maps he claimed are unfair to Democrats.

Elias Law Group has raked in millions of dollars since Elias launched it in August. The DCCC paid the firm $424,048 in December, according to campaign filings. The Democratic Senatorial Campaign Committee paid the firm $492,560. Senate Majority Leader Chuck Schumer’s (D., N.Y.) Senate Majority PAC paid Elias Law Group another $162,797.

The firm received another $40,000 collectively from Priorities USA Action, the Congressional Progressive Caucus PAC, George Soros’s Democracy PAC, and former attorney general Eric Holder’s National Democratic Redistricting Committee. The Lincoln Project, the anti-Trump PAC founded by former Republican operatives, paid Elias Law Group $45,288.

Of all of Elias’s legal maneuverings, his work with the DCCC could have the most political impact in November. Elias and Maloney have pushed for changes to congressional districts that could help Democrats pick up as many as seven seats.