Was it ok to break up with abusive boyfriend via sms?

My boyfriend abused me verbally. When he blocked my arms, pressed to the bed and shouted in face to make me do things he wanted me to do, I left his apartment in terror. The next morning I messaged him that I’m grateful for good things we had but I cannot take the humiliation anymore and broke up. Was it okay for me to break up via sms if I was abused?
Was it ok to break up with abusive boyfriend via sms?
Post Opinion