Yes; they cannot take any risks with that, laws around showing porn to people / minors (accidentally or not) are stricter than copyright violations. I'm not a legal expert and honestly I'm pulling this out of my ass, but, porn is a legal matter, but copyright violations is a civil matter.
There's also the advertisers and payment processors to consider, most of them will have nothing to do with porn. This triggered some major pruning of various websites too, Tumblr and Reddit on the one side, but huge chunks of Pornhub and co as well for any porn that didn't come with the right paperwork, including identification and consent forms from the participants.