Hillary Clinton has reached the number of delegates needed to clinch the Democratic U.S. presidential nomination, according to tallies on Monday by two US media outlets.

Six states are still set to vote in nominating contests, Reuters reports.

A former senator and US secretary of state, Clinton would be the first woman to ever be the presidential candidate of a major political party in the country’s 239-year history.

But the campaign of her rival, Bernie Sanders, vowed to keep up the fight in what has been a protracted and increasingly antagonised primary race that has exposed deep rifts between the left-wing and the more centrist of the Democratic Party.

A Sanders campaign spokesman said it was wrong of the Associated Press and NBC News, which made the calls on Monday evening, to count the votes of superdelegates before they cast ballots at the Democratic National Convention in July.

“Our job from now until the convention is to convince those superdelegates that Bernie is by far the strongest candidate against Donald Trump,” Sanders’ spokesman Michael Briggs said in a statement, castigating what he called the media’s “rush to judgment.”

While most delegates are awarded by popular votes in state-by-state elections, superdelegates largely consist of party leaders and elected senators, members of Congress and governors, and can change their mind at any time.

For that reason, the Democratic National Committee has echoed the Sanders campaign, saying the superdelegates should not be counted until they vote at the convention in Philadelphia.

But that has not deterred the news media. The AP and NBC reported that Clinton reached the 2,383 delegates needed to become the presumptive Democratic nominee with a decisive weekend victory in Puerto Rico, a U.S. territory, and a burst of additional support from superdelegates.