ADVICE!!!! WHAT TO DO

So me and this dude have known each other for 3 years (he also always liked me) and last year he dated one of my friends that I'm not really close to, but still good friends with. Recently, me and him had sex but we tried keeping it lowkey. HOWEVER, all my other friends and people know about us having sex and doing things but not my friend who dated him. I feel bad but it just sort of happened (and more than once). What would you do if you were in my situation?