Lawmakers looking to prevent a repeat of an HIV outbreak that has rocked a southern Indiana county sent Republican Gov. Mike Pence a measure Wednesday that would allow communities to implement needle-exchange programs if they can prove they're in the midst of an epidemic tied to intravenous drug use.

Pence, who opposes needle exchanges as part of anti-drug policy, said in a statement Wednesday that he looks forward to signing the legislation into law.

He said his office worked with lawmakers to develop "a legal framework" that would give state health officials the resources and flexibility they need to handle health emergencies.

The proposal will enable the "state's healthcare and law enforcement communities to address this and future health crises." Pence said.

The bill allows areas that can prove they're in the midst of an epidemic to seek approval from the state health commissioner to launch a needle exchange. If Pence signs off, the measure would mark the first time Indiana law has allowed needle exchanges to combat outbreaks of disease.

The House voted 80-19 to approve the measure. The Senate approved it on a 38-11 vote.

The legislation comes as Indiana battles its worst HIV outbreak in decades. Health officials say 143 people with ties to Scott County, about 30 miles north of Louisville, Kentucky, and adjacent Jackson County have tested positive for the virus that causes AIDS. The cases are tied to needle sharing among people who injected a liquefied form of the painkiller Opana.

Pence in March approved a limited needle-exchange program for Scott County as part of an executive order declaring a public health emergency. He extended that order last week, allowing the exchange to continue until late May as part of a broader effort to contain the outbreak. More than 7,100 clean needles had been distributed as of Tuesday.

Rep. Ed Clere, R-New Albany, said he was pleased that lawmakers opened the door to broader uses of needle-exchange programs to "keep their community from being the next Scott County." But he acknowledged that the issue remains divisive and said some at-risk counties might not be able to meet the criteria to establish a program.

Local officials must show that an epidemic is spreading through IV drug use and that an exchange program would be part of an appropriate public health response.

"For some this doesn't go far enough. For some, it goes too far," Clere said.

Opponents have argued that the bill could hinder drug-treatment efforts and create a legal defense for people arrested for possessing drug paraphernalia. But health officials repeatedly cited studies showing that needle exchanges are effective tools in curbing outbreaks.

Rep. Matt Pierce, D-Bloomington, supported the bill but said the stigma attached to needle-exchange programs could prevent counties from participating.

"They'll be reluctant to because they think it will put a scarlet letter on them and cause problems," he said.