On Thursday, the California State Assembly approved SB 277, a bill that would require all students enrolling in public or private school to be vaccinated unless a doctor recommends otherwise. The controversial legislation eliminates exemptions based on religious or personal beliefs. It passed 46-30.

“As a mother, I understand the decisions we make about our children’s healthcare are deeply personal,” Assemblywoman Lorena Gonzalez told the Los Angeles Times. “While I respect the fundamental right to make that decision as a family, we must balance that with the fact that none of us has the right to endanger others.”

The bill now heads to the Senate, which approved a previous version of it earlier in June, and the governor's desk. Gov. Jerry Brown hasn't explicitly said whether he would sign the measure, though his spokesman told the Associated Press that he "believes that vaccinations are profoundly important and a major public health benefit."

If passed, the legislation would give California one of the nation's strictest laws on vaccinations. Although 32 states have rules prohibiting exemptions based on personal and moral beliefs, only two extend the ban to religion: Mississippi and West Virginia.

Discussion around SB 277 was heated, with parents and conservatives arguing it took away their rights to decide what's best for their children, who would have to be vaccinated against illnesses such as whooping cough in order to foster "herd immunity." Any unvaccinated student would have to produce proof of a serious health issue or be homeschooled. "We do not have the right, nor should we have the power, to take away a parent's right to choose," Assemblyman Devon Mathis told AP.

SB 277's authors, Richard Pan and Ben Allen, told the San Jose Mercury News vaccination was important because it could prevent vulnerable students from catching and spreading diseases. They pointed to the December measles outbreak that started at Disneyland and eventually sickened about 150 people in California, Mexico and Canada.