I got wedged between the door and the wall.

Long story short I was trying to get in a door while someone was pushing it. They were squeezing me pretty hard and I couldn’t get out. My chest hurts really bad, especially when I breathe. It’s starting to get worse but I don’t know if I should worry. I’m thinking it may just be the muscle or bone that’s sore but it’s hard to breathe especially when I stand up. Is it worth going to the ER?