Lead pipes, and lead solder, weren't the problem. Lead doesn't dissolve easily in water. The problem is mild acids. Consider that the Romans used lead cups to hold wine & drink wine out of, and lead bowls to boil down unfermented grape juice. Both lead to the formation of lead carbonate, which dissolved easily, and had a pleasant sweet taste of its own which the Romans liked.
SO depending on what was in the tin, this may not have been a problem. Early tins weren't tin - they were iron, and rusted, which was bad for the food inside. So they gave it a 'wash' of tin, which prevented rusting - but if you dented the can, this broke the layer, which led to the iron underneath rusting, and the food spoiling. Remember, fellow oldies, being told not to pick dented cans? That's the memory of that.
Cans now are steel (which doesn't rust unless badly made, or badly treated), or aluminium (which doesn't rust due to forming a protective layer of oxide.) Either way, denting a modern can lightly is not a risk.