He's nice enough not to want to be associated with a nasty remark but not nice enough not to make it. Lacking the courage of one's nastiness does not make one nice.
I guess the tone of jokes is often, at best, irreverent, but it always comes from a place of deep love.