The Republican state official tapped by President Trump to lead his sketchy voter fraud commission was sanctioned by a federal judge Friday for his “deceptive conduct and lack of candor” in a voting rights case brought against him.

Kansas Secretary of Kris Kobach will have to pay the court a $1,000 fine as punishment for “patently misleading representations” during the litigation over the proof-of-citizenship voter registration requirement Kobach is seeking to implement in his state.

As part of its lawsuit challenging the requirement, the ACLU asked the court to sanction Kobach for how he handled the group’s request to view documents believed to be proposals to amend the National Voter Registration Act, including a proposal he was photographed holding while meeting with Trump back in December. The ACLU’s legal challenge against his proof-of-citizenship requirement claims it to be in violation of the NVRA, making the documents potentially relevant to the case.

U.S. Magistrate James P. O’Hara did not grant the ACLU everything it was asking in response to Kobach’s slow-walking of their request. However, along with the fine, the ACLU will also be allowed to depose Kobach about the proposal, though the deposition won’t be made public, according to Thursday’s order.

The judge was willing to give Kobach credit that his initial legal arguments opposing the ACLU’s request for the documents to be “substantially justified” grounds, even though the court eventually ruled against him in what it then described as a “very close call.”

“Defendant’s positions began to go awry, however, after plaintiffs filed a motion to compel production of the two documents. In response to the motion, defendant made patently misleading representations to the court about the documents, which at the time had not been produced to either the court or plaintiffs, such that the court was required to take defendant at his word,” the judge said Friday.

Once the judge had the opportunity to review the documents, he found that on multiple occasions Kobach’s legal arguments against handing them over muddied the waters about how the documents related to the case.

According to the court, Kobach gave “the strong impression that neither of the two at-issue documents relate to proposals by defendant to amend the NVRA’s eligibility-assessment provisions. Upon in camera review of the documents, the undersigned learned this is clearly not the case.”

“The court cannot say that defendant flat-out lied in representing the content of the disputed documents. In his response to the motion for sanctions, defendant attempts to defend his representations by thinly parsing the wording plaintiffs allegedly used,” the judge said.

Friday’s order denied the ACLU’s request that certain redactions placed on the documents be removed. However, the ACLU will get an hour to depose him next month, even as Kobach has argued that the ACLU should seek more information about the documents through written inquiries.

Kobach, who also recently announced a run for Kansas governor, is the vice chair of the dubious voter fraud commission Trump created after repeatedly, without proof, claiming that the millions of people voted illegally in the 2016 election, claims that Kobach himself did not dispute. Voting rights advocates worry that the so-called “Presidential Commission on Election Integrity” will be used as a cover to push restrictive voter laws like the one Kobach is currently battling in court to defend.

The $1,000 fine the court slapped Kobach with Friday came with a written scolding.

“Although conduct resulting in the imposition of sanctions typically has a negative, but short-term, financial impact on counsel or his client, it usually has a much more sustained impact on the reputation of counsel—both among judicial officers and the practicing bar,” it said.