re: Deflated cupcakes?? Help!

I know that if the baking soda/powder is expired then it won’t rise, another idea that comes to mind is when making cakes if you slam it in the oven, place it too hard or do anything to overly disrupt it they could deflate in the middle not create a dome or rise as much. I don’t know if that transfers to cupcakes but it’s worth saying