I don't think there's a joke here, or at least I'm not reading it this way. If anything it's not about "weaklings" but about being in an area where people are more likely to sue a business if they aren't warned beforehand - a street vendor elsewhere will not ask because their risk profile doesn't include being sued by someone who bought ice cream from an ice cream truck.
Like if you walk into a store and they offer you coffee or even a glass of prosecco, I would also say to my wife "oh we're in that kind of store now" because you know you're about to be ripped off in some way. Not that other stores are for weaklings.
Possibly something more like "people who have non-imaginary dairy allergies aren't likely to go into an ice cream shop, and even if they do, they obviously won't order without emphasizing their dairy allergy".
It's kind of similar to the Whole Wheat Bakery asking you whether you're OK with gluten. If you aren't, you made a big mistake walking in.
Affluent areas in general have more variety. The ice cream shop may be a place where you can get all kinds of ingredients that you wouldn't find at other places. This is 100% true for "fine dining" and it's one reason why they ask.
They will also have substitutes for an allergy to make the experience just as pleasant, thus they ask.
Do they ask every single customer if dairy is okay? Because that was the original point... not that the ice cream shop also offered non-dairy versions.
A dairy allergy is perhaps one thing, but it's always great when ice cream places offer non-dairy alternatives. I'm extremely lactose intolerant and it means I can actually get a treat along with my wife/kids.
In this case, the joke is that someone with a dairy allergy could somehow buy and eat ice-cream without knowing it contained dairy.
It's just a completely ridiculous thing to check. Like warning that the boiled peanuts contain peanuts, or that a pencil sharpener should not have fingers inserted into it.