We didn’t know it is so risky to go to a restaurant. Alex does several successful attempts to pretend to be a waiter and manage to get the credit cards from customers sitting outside restaurants. One of the reasons he asked for the credit card (before food is served) is that the customers are sitting outside.
Perhaps it makes sense to install CCTV, but that would not prevent the scam artist from doing his tricks either.
Probably the best way to prevent such a scam is to pay up after receiving the food.