> I am certain that if the same line had come from a lady, no one would have found it offensive.
Well yes, because context matters. When you have a power disparity, comedy only goes one way - if a member of a majority group makes disparaging remarks about a minority group, that's not funny, it's straight-up bigotry.