David Whitley, the Texas secretary of state, resigned Monday just before he would have been booted anyway after failing to secure Senate confirmation to stay on the job.

According to the Austin-American Statesman, despite unanimous Republican support, all Democrats opposed the confirmation due to Whitley’s leadership of an investigation into the citizenship status of voters which resulted in multiple lawsuits and a court settlement freezing the probe.

Whitley had identified 100,000 people on the rolls that he thought were ineligible to vote, over half of whom had cast a ballot since 1996, and referred them to the Texas attorney general for possible prosecution.

It was soon revealed that many of the voters were naturalized citizens fully within their rights to cast a ballot. Whitley’s office later admitted that they knew some naturalized voters may have been on the list.