hopeless

Ta
I'm so frustrated and I feel like my love life is hopeless. I was in a new relationship with a guy and he had a female friend who had a crush on him which he said was annoying and he didn't like her and he never had and then ten days after we made it official he just texts me and says I'm with her now we're dating with no warning. I feel so angry because if he didn't like me enough to stay with me or had feelings for her then why did he bother to make it official it just hurt so much and felt so pointless to me like I got my hopes up for nothing