The vinegar is to help add an extra “tang” to the cream cheese frosting and offset the sweetness. You can leave it out if you’d like, but I highly recommend it for balance and complexity.