AUGUSTA (AP) — The Maine Legislature gave final approval Thursday to a proposal to expand access to abortions later in pregnancy, sending the bill to the governor for her signature.

Once signed into law by Democratic Gov. Janet Mills, as expected, Maine will have one of the least restrictive abortion laws in the country.

Current state law bans abortions after a fetus becomes viable outside the womb, at roughly 24 weeks, but allows an exception if the patient's life is at risk. The bill would allow abortions at any time if deemed medically necessary by a doctor.

The Senate enacted the bill 20-11 on Thursday, sending it to the governor's desk.

Democrats control both chambers of the Maine Legislature but that didn't prevent emotional debate over the proposal, with opponents regularly appearing in the State House to make their voices heard.

Some opponents of the bill said it goes too far, allowing a major expansion of abortions and putting too much trust in doctors to say when the procedure is appropriate. Supporters said the bill would apply to patients only in rare instances in which patients learn later in pregnancy that the fetus won't survive.

Republican Sen. Eric Brakey of Auburn said Thursday it was difficult to understand why other lawmakers didn't include language requiring doctors to make a fatal diagnosis, and he expressed concern about the bill's language being "used as a pretext for something much bigger."

He didn't clarify further, and urged the bill's supporters to vote it down.

But Democratic Sen. Anne Carney of Cape Elizabeth said the bill was about showing compassion for people in a difficult circumstances.

"There's no pretext," Carney said. "What the bill is really about is ensuring that women and families get the most compassionate health care they can — and the most accurate, medically necessary health care within the medical standards of care, in these tragic circumstances."

Currently, only six other states leave the decision to get an abortion to doctors and their patients, without restrictions. They are Alaska, Colorado, New Jersey, New Mexico, Oregon and Vermont, plus Washington, D.C.

Abortions later in pregnancy are rare. Nationally, about 1% happen after 21 weeks, according to U.S. Centers for Disease Control and Prevention tallies, which do not have full data from every state.

Mills said during her reelection campaign last year that she was content with the existing abortion law but since then, she changed her mind.

In January, the governor was joined by legislative leaders in unveiling a proposal to expand abortion access in response to the story of a Maine woman who had to travel to Colorado for an abortion after discovering 32 weeks into her pregnancy that the fetus would not survive outside the womb.

___

Associated Press writer Geoff Mulvihill in Cherry Hill, New Jersey, contributed to this report.