My friend told me about their affair

My friend, who is due to get married in a few months, has told me she’s been having an affair with a married coworker since last year. Apparently it was just a one off to start with, but now it’s progressed to a full blown affair with them meeting several times a week.

I don’t in any way condone cheating, but I can understand why some feel pushed to it if they are unhappy/trapped in their relationship. What I really don’t understand about this is that she said she cannot fault anything with her fiancé and nothing about him makes her unhappy, it’s just a case of this coworker being ‘exciting’. She has no intention of either ending the affair or not going ahead with the wedding. I told her I’m concerned about the repercussions if she gets caught (in my opinion she has a lot to lose from this), but she doesn’t think there’s any chance of them getting caught out. I don’t know why the whole thing is making me so anxious when I’m not even involved, but I can’t stop thinking about it.

I’m so lost on how I should feel about this whole thing. I don’t want to lose them as a friend because they’re an important part of my life, but at the same time I just can’t look at her the same way. How am I supposed to just carry on being a part of her and her fiancés life, and being a part of their wedding when I know this is happening?