Fasting?

Did any of you have to fast before getting local anesthetic before wisdom teeth extraction? I’m getting numbed for mine but they told me I couldn’t eat for 6 hours? I thought that was only if they put your to sleep