The law will allow the government to act against platform providers who fail to filter out harmful content.