A Kentucky judge has struck down a measure that would have weakened Democratic Gov. Andy Beshear’s appointment authority over a key ethics commission by shifting power to Republican officials to select a majority of the members.

In his ruling Monday, Jefferson Circuit Judge McKay Chauvin said the measure severely “diminishes and diverts” the governor’s constitutional duty to ensure the state’s executive branch ethics code is “faithfully executed.” By shifting appointment authority away from the governor, the law empowered other constitutional officers who aren’t “charged with that same constitutional duty,” he said.

The GOP-dominated legislature passed the measure – House Bill 334 – this year over Beshear’s veto. The new law was set to take effect Thursday but is now blocked by the judge’s decision.

Republican Attorney General Daniel Cameron’s office said the ruling will be appealed.

Under the measure, five statewide officeholders – currently all Republicans – each would make one appointment to the reconstituted state Executive Branch Ethics Commission. Those officials are the attorney general, secretary of state, state treasurer, state auditor, and agriculture commissioner.

The governor would appoint two members to the panel that enforces the executive branch’s ethics code. The measure would have removed all five current commission members – all gubernatorial appointees.

Beshear filed a lawsuit aimed at blocking the measure, calling it an unconstitutional incursion into executive branch powers. The governor also warned that the commission’s revamped membership could launch politically based, meritless investigations.

The legal fight comes a year before Beshear will be on the statewide ballot seeking a second term in a state increasingly dominated by Republicans. It’s the latest in a series of court confrontations over Republican-backed laws that would weaken the Democratic governor’s executive authority.

The governor’s office hailed the circuit judge’s ruling in the ethics commission case.

“This is an important ruling that shows the rules stay the same for everyone and that Gov. Beshear has the same authority as every governor before him,” Crystal Staley, the governor’s spokeswoman, said in a statement Tuesday. “This was an attempt by the General Assembly to politicize and even weaponize the Executive Branch Ethics Commission.”

The circuit judge in Louisville ruled that the law was unconstitutional, saying it “improperly impedes” the governor’s executive authority and “effectively creates a superior executive body.”

Cameron has called the ethics commission-related law a “good-government measure.” Cameron is among the Republicans seeking to challenge Beshear in next year’s election.

“We are disappointed with the court’s ruling and will be appealing,” Elizabeth Kuhn, a spokeswoman for the attorney general’s office, said in a statement Tuesday.

State Auditor Mike Harmon, who also is running for governor next year, said he disagreed with the ruling and said he looked forward to “joining with my fellow constitutional officers” in appealing.

In his ruling, Chauvin said that maintaining the “integrity and independence” of each branch of government is “vital to our democracy.”

“An incursion by one branch of government into the powers and functions of another threatens the balance of power purposely and purposefully established in the Kentucky Constitution as foundational to our democracy,” the judge wrote.

Chauvin called it a “balance that has been remarkably robust over time but remains at all times perilously fragile.”