was I wrong for telling ?

I worked at a camp this passed summer and my  good friend came along . Later in the summer a guy who she had been on and off with started working there . They started talking again and she seemed really into him. Before summer camp was over there was a girl who was a nurse and she telling me that the guy confided in her that he was gay and he was using my friend to stop being gay. He was very feminine and never hung out with guys which a lot of people noticed . However, even before she told me rumors were going around that he was gay . I was just at my breaking point because he was always talking about gay people and how gross they were and then for him to play my friend just sickens me . I told my friend about it because it was eating me inside . She confronted him about it and he lied to her and said he wasn't that we were lying to her . Later it came out by family member that it was true . She was hurt but she said she rather be hurt then in a marriage with a liar who left her for a man. Did I do the right thing by telling her ?