I've really messed up😭🤦😴

My son is 8 months old and he always took his naps with me(on my chest or next to me). I know I shouldn't have😭 but I loved having my sweet boy right there with me. But when it came to bed time he slept in his crib. Well this past week he won't sleep unless he's with me or he'll only sleep a couple hours then he's awake and crying. He use to be such a great sleeper at night. Only waking once if at all. He would sleep 6-7 hours before waking for a feeding. Now its every 2 hours. 🤦 I know I messed up. How do I fix this? I feel like such a bad mom. I feel like I really screwed up and now my son, husband and I are paying the price for my dumbass 😭. Any advice would be great I'm willing to try anything at this point 🤦. Please no hate I already beat myself up enough I don't need any help in that department.

TIA