Unfortunately, and weirdly, untrue.
There is no law requiring anyone to check id or even look at the name, nor a law protecting the establishment if they decide to go that extra step to protect the cardholder.
VISA and MasterCard do however have their own policy regarding ID-checks: You cannot require a cardholder to provide identification of any kind. If the cardholder refuses to show id, no matter what the store policy, or what the card itself* says, the merchant agreement with Visa and MC requires them to process the card in good faith, or risk losing their account entirely.
Several large companies of course routinely ignore this (and aren't corrected because it's big money they're processing) but a small convenience store can lose their account for a variety of reasons, which means a lot of hassle.
The only thing that would protect the store in that case is if the clerk KNEW for a fact that the person presenting a card wasn't the cardholder listed, without asking for that ID. As in, willing to swear in court that it's not, not "No way his name is Shirley" sure.
Of course, he bought cigarettes too, so they could have checked the ID for that, and then they would have been sure, and THAT is protected by law on any transactions including tobacco in most states (and almost as many states on alcohol sales)
* Know all those people that sign their card as "Check ID"? The card isn't valid unless it's ACTUALLY signed. You can put extra instructions on there, but it doesn't matter either way, and the merchant IS allowed (in fact, required in their contract with Visa/MC) to deny the card without the signature appearing, as the card isn't considered valid unless you agree to all terms of using it, which is done by signing