New York's top court on Wednesday rejected the congressional and state Senate maps drawn by the Democratic-led Legislature earlier this year as unconstitutional in a key victory for Republicans. 

The 4-3 ruling could upend the scheduled June party primaries and force lawmakers back to the drawing board to draw new maps. 

The court found "the enactment of the congressional and Senate maps by the legislature was procedurally unconstitutional, and the congressional map is also substantively unconstitutional as drawn with impermissible partisan purpose, leaving the state without constitutional district lines for use in the 2022 primary and general elections."

The ruling is a victory for Republicans who had challenged the maps in state court on the grounds the new districts favored Democrats and violated the state's constitutional ban on partisan redistricting. 

New lines will be now be in the hands of what's known as a "special master" appointed by a lower court this month, according to the ruling. 

"With judicial supervision and the support of a neutral expert designated a special master, there is sufficient time for the adoption of new district lines," the court ruled.

Early voting for New York's primary is scheduled to begin June 18, and petitions were already submitted based on the maps approved in February. But the ruling raised the possibility of a moving the primary to August as a result. 

"We are confident that, in consultation with the Board of Elections, Supreme Court can swiftly develop a schedule to facilitate an August primary election, allowing time for the adoption of new constitutional maps," the majority opinion stated.

The ruling did not appear to affect the maps drawn for the state Assembly. At the same time, the ruling was silent on whether the primary voting should be split for the statewide contests coming up in June for governor and lieutenant governor. 

Democratic officials had insisted the maps were drawn fairly and reflected the party's enrollment advantage over Republicans. 

But Republicans as well as good-government advocates decried the maps as unfairly weighted toward Democratic incumbents and candidates. New York is seen as a potentially pivotal state for Democrats to maintain control of the narrowly divided House of Representatives this year. 

Lawmakers and Gov. Kathy Hochul had previously raised the possibility of changing the primary election if the maps were rejected.

Democrats in the state Legislature took control of the redistricting process earlier this year after a commission meant to remove the power to draw district lines failed to reach an agreement on the new maps. 

A Republican-backed legal challenge to the maps was filed after they were signed into law by Gov. Kathy Hochul on the grounds they violated the state's 2014 amendment banning partisan redistricting. 

Good-government experts and political scientists have said the use of partisan-draw legislative districts -- allowing officials in power to, in effect, select their own voters -- has contributed to the rise in polarization across the country. 

With fewer contested general elections, candidates are more apt to face stiffer challenges in party primaries, forcing them to appeal to their parties' bases as a result. 

The ruling on Wednesday, handed down with just over a month to go in New York's legislative session, left deep uncertainty for the political calendar as approved. 

"We are reviewing the decision," said Mike Murphy, a spokesman for the state Senate's Democratic conference. 

Republicans, meanwhile, celebrated the development. 

"Despite Democrats’ attempts to inject partisan politics into this process, New Yorkers will now get what they voted for," said Senate Minority Leader Robert Ortt. "We look forward to a special master producing fair, independent maps for the people of New York."