in love with my friend

I confessed to a guy 2days ago that I love him.. we've been friends for almost 7 months. he really is the sweetest thing and I thought we were in the "talking stage"..but he says he doesn't like me back enough and also doesn't do commitments..idk the details of his last relationship (he's had one) but he says he broke up bc he didn't like the title it came with, he also said he still likes the girl.. I thought the best thing to do was to cut off all contact with him, but that seems childish bc he's done nothing wrong to me..how do I get over him while keeping our friendship tight?.. please help!😩😩

please help