When I have been having a table that has complained about the meal and had it bought for them afterwards and consumed a free dessert on top of it , I always say this when I present the bill.
But for it to work you have to be completely sincere because if you are not it could backfire on you.
I say this , ” I hope the next time you come to the restaurant I will have another chance to serve you.”
If you say it right it totally freaks them out. Cause up to then they think they have been a big bother but when they hear that they give a sort of nervous chuckle and when they see you mean it they go away happier if not astonished that you would say such a thing.
Sometimes I would say it helps out with the tip at the end of the meal.
Like you actually showed you cared about their experience and want to turn it around to a more positive experience the next time they dine.
Try it but when you do you have to look them in the eye and say it sincerely.