neb:MadEngineer: That’s an offence
https://www.mpi.govt.nz/contact-us/make-a-food-complaint/report-food-being-sold-past-its-date-marking/
But note the different markings which the linked article also points out, there's a difference between "best before" and "use by", as well as other vague labeling like "sell by". Also, a lot of food isn't required to have any date marking on it, like the tins of buffalo meat marked "US Cavalry" that we have stored under the sink. Conversely, where there's a legal requirement to put on a date marking the date may be well short of the actual lifetime of the food, Twinkies come immediately to mind.
For the OP, what food was it and what exact date marking was on the food?
Shredded chicken, a cake, ground coffee, ham, biscuits and soup spring to mind.