Rep. Jerry Nadler defeated his colleague Rep. Carolyn Maloney in a vicious House Democratic primary in New York.

The two lawmakers were pitted against each other after a redrawn district map spurred the longtime colleagues to compete for a single seat in Congress.

Nadler chaired the House Judiciary Committee, while Maloney led the House Oversight Committee.

Rep. Jerry Nadler defeated his longtime colleague Rep. Carolyn Maloney in a contentious Democratic primary Tuesday in New        York’s newly drawn 12th Congressional District,

He’s all but guaranteed in November’s general election to win the heavily Democratic district, which merged Manhattan’s Upper West Side and Upper East Side into one and pitted the two long-serving lawmakers against each other.

After he cast his ballot Tuesday morning on the Upper West Side, Nadler, 75, told NBC News he intends to keep his top spot on the Judiciary panel if he is reelected.

“Absolutely, I’ll seek to remain the top Democrat on the Judiciary Committee, and I don’t think there’s much question that that’ll happen,” Nadler said.

“What I want to achieve is, I believe this country is really a democratic system — with a small d — is threatened.

If Republicans win control of the House this fall, Nadler would lose his committee gavel and likely serve as ranking member.