Understaffing doesn't justify crime. You probably understaff your home security, leaving it empty all day while you're at work. Do you deserve to be robbed?
Noting the existence of theft throughout the ages is not an endorsement.
My point is that we should be careful who we ask to pay for enforcement. It's expensive to maintain a system of courts and jails for petty crimes. Rikers is a rather egregious example, but almost $1 billion per year where 85% of detainees are pretrial!
I think it's legitimate to ask to what exent the community should cover the enforcement cost.
The community pays either way - they are the source of the revenue that has to cover any private enforcement! Law enforcement is a public good and will be under supplied by private parties that cannot internalise all the gain!
When you spread the risk out among thousands of homes near you, a door with a lock may well be a “sufficiently staffed” home. Meanwhile stores may be the only game for several blocks, miles even depending on which part of the country.
Understaffing and such things are like having locks on your house, yet only locking the windows while leaving the house, garage, and shed doors open. You may not deserve to have your stuff taken, but everyone can understand why they chose your house instead of the one next door. If you aren't willing to do the bare minimum - shutting doors and locking them - you were minimally more OK with the risk.
And to be fair, retail places usually aren't "robbed". They have their stuff shoplifted and stolen: Robbing a store generally creates images of armed intruders, and most of it isn't like that.