The Democratic Party could replace Maine Senate candidate Graham Platner on the general election ballot if he wins the primary and subsequently quits before a specific date, according to state law.

A candidate “nominated for an office at a primary election” can withdraw by 5 p.m. of the second Monday in July preceding the general election, under a Maine statute. The state Democratic Party committee may then “make a replacement nomination for the general election” by 5 p.m. of the fourth Monday in July.

If Platner wins the Democratic primary on June 9, the statute provides Democrats with a potential path to replace him in the Maine Senate race against incumbent Sen. Susan Collins (R-ME). Platner would have to voluntarily withdraw his name on or before July 13, potentially in response to calls from Democrats for him to step aside, before the party could nominate his replacement before the end of the month.

Platner found himself again embroiled in controversy Saturday after his campaign confirmed that his wife told an aide last summer she was aware of sexual texts her husband had sent to “several women.”

The report raises questions about Platner’s future in the race as Democrats seek to regain control of Congress in November’s midterm elections. Platner originally came under fire last October after vulgar social media comments surfaced, and it was reported that he had a tattoo of a Nazi symbol.