<human>: Can you condense the text into a few key points?

I have been dating my girlfriend for about a year and a half and just the other day my friend was talking to my girlfriend and told her how my last relationship ended. Now, my girlfriend knew a little about it, but I've been reluctant to give her the full details because quite frankly I was a dick. I acted immature, stupid, and childish which eventually destroyed any trust I had with my ex. It took me quite a few months to really forgive myself for how I acted. I have since been dating another girl and I haven't been anything but honest with her in our relationship. I know I have been placed in very similar situations in this current relationship where in my previous relationship I behaved in ways that betrayed the trust with my girlfriend at the time. However, in these situations I behaved in the ways I should have behaved then. I've learned from my mistakes in the past.

But now something that was never part of my current relationship and shouldn't have ever been a part of it is now a part of it. I feel like her knowing what I did in a previous relationship hurts the trust we have now. I've been nothing but faithful to her in our entire relationship. I can sleep well at night knowing that I learned from my previous mistakes and I treat this one right. But I'm not sure if our trust is damaged because my friend decided to open his mouth. It's also important to note we've been dating for a year and a half and haven't had any trust issues up to this point.
<bot>: My friend told my current gf (23, F, dating 1.5yrs) about my past mistakes with a previous gf. I feel like it might have damaged our trust. Did my friend do the right thing?