BATON ROUGE, La. (CN) – A Louisiana judge on Wednesday blocked an executive order offering protections to LGBT employees in state government as unconstitutional and an overreach of the governor’s authority.

State District Judge Todd Hernandez ruled that Democratic Gov. John Bel Edwards acted outside the scope of his authority when he created the anti-discrimination law with an executive order.

The order, issued last April, prohibited discrimination against sexual orientation and gender identity in government and state contracts.

The ruling was a win for Republican Attorney General Jeff Landry, who challenged the anti-discrimination order. Landry has reportedly blocked dozens of state contracts that contained an LGBT provision from moving forward.

“I applaud Judge Hernandez for basing his ruling on the law, not politics,” Landry said in a statement. “My challenge has always been about upholding the checks and balances on executive authority as established in our State Constitution.”

Gov. Edwards said he plans to appeal Judge Hernandez’s decision.

“We continue to believe that discrimination is not a Louisiana value and that we are best served as a state when employment decisions are based solely on an individual’s qualifications and job performance,” the governor said in a statement.

In October, a judge found that the governor did not have the right to sue the attorney general to force the approval of legal contracts that contained an LGBT provision.

Edwards said his executive order contained an exception for contractors that are religious organizations, and is a statement that Louisiana doesn’t discriminate.

Landry argued that it sought to establish a new protected class of people that isn’t recognized under the law, and which legislators refused to add.