teeth xrays safe? I'm only about to be 8w pregnant.

Guys what do I do?
My tooth has been killing me all week. 
And there's also a tooth that's decaying in the back.
Can I get the tooth pulled?
And can I get X-rays done?
I don't want anything at all to the happen to the baby 😔