INDIANAPOLIS (AP) — Indiana state lawmakers advanced a measure Wednesday to strip legal protections for school libraries if their educators are accused of assigning texts harmful to students.

Worries that sexually inappropriate or “pornographic” materials are available to children in Indiana school libraries clashed with concerns the legislation could open the door to criminal prosecutions of educators for providing books about so-called controversial topics.

The Senate committee meeting resulted in a 7-4 vote, largely along party lines. The legislation, which now advances to the full Senate, would affect K-12 public and charter school libraries.

“They’re in these libraries; these books are available,” said Republican Sen. Rick Niemeyer, echoing the testimony of several parents who said their kids’ school libraries contained books unsuitable for their age. “The only thing I can think about, to do something about this, is get these books out of their libraries, especially for the young kids.”

But several residents also testified that such complaints were limited and resolved by locally approved procedures.

“What exactly is the purpose of this bill?” asked Marily Graber, a retired teacher and board member of a public library in Goshen, Indiana. “I worry that if the bill is passed, it will have a chilling effect on librarians and teachers.”