Boyfriend gave me chlaymedia.

So hear me out first. Me and my boyfriend got together in January of this year. He was with other people before me. Last week I went for an women’s annual exam and I got tested positive for chlaymedia and I’m obviously devastated because I assumed I got cheated on. He says he’s very embarrassed and keeps apologizing because he said he swears he didn’t know and he says he must of gotten it before we got in a relationship. I don’t know what to do. I part of me feels the need the walk away but another is telling me to be understanding since he didn’t know. What’s your opinion?