@Pieandchips1234456
I had hoped it was a mistake and I was being insecure, which I can be
Well, you are right in that you are insecure, but the security you lack is not trust in your partner to be loyal to you, but it's a lack of security in your own standards.
My guess is that in your heart, you do not want to be with a man who sends flirty messages to another woman. You believe the behaviour is disloyal, unkind and shows a lack of commitment to you. You feel hurt by it.
And yet when you saw the man you are in a relationship with behave in exactly this way, and were faced with the decision to eject him from your life, you paused. You felt or told yourself something like 'Well, he does have a lot of other good qualities. Maybe this kind of flirty behaviour is actually what all men do and does not mean his loyalties are divided between me and other women. Maybe it is all right for him to give lavish compliments to other women as long as he is not actually physically putting his dick in them. Maybe if there are real 'one-women men' out there, I am not sufficiently attractive/interesting/valuable to attract one, so this is the best I can hope for."
In short, you doubted your own standards, and here you are, in a relationship with a man who you know quite well could have one foot out the door.
That's why you feel insecure. Because you ignored behaviour that showed your boyfriend has different standards in a relationship to you.