The main purpose of this legislation is to provide legal protection to certain entities from being held liable for environmental damages related to specific harmful substances known as perfluoroalkyl and polyfluoroalkyl substances (PFAS). These substances are often found in water systems and can pose health risks. The law aims to encourage water and wastewater treatment facilities to manage these substances without the fear of facing costly legal repercussions under existing environmental laws.