Restaraunt tip: was this ok, or not?

Hello, I’m Kaio and I declared my cash tips. Nice to meet you. I did round up or down to round numbers, but then again so does TurboTax so presumably the IRS is cool with that.

The reason I preferred cash tips, and why I tip in cash whenever possible, is the aforementioned very common restaurant policy that takes the credit card processing fee out of the server’s tip before the tip is handed over. That pissed me off, since if a business is going to accept credit cards, they should accept that processing fees are a cost of doing business that way. If the tip wasn’t charged on the card, they couldn’t take the fee from anyone but themselves.

I have been told that it’s not legal; I never verified that one way or the other, but either way it never stopped management from doing it.