Dental work during pregnancy

Miss
Any have dental work during pregnancy. I am 18+6 and had to have a filling. I was not anticipating the needle in my mouth. Didnt even think about whether its safe or not. My dentist is aware that I am expecting.