That's also called a toxic workplace if there is a pattern of feedback like this.
If it is, and if you can, start looking elsewhere. Personal attacks over what should be mundane code review items is unacceptable.
If this was in formal code review, then that's still a huge red flag. Code review is about catching errors, learning opportunity, and periodically style/cleanliness problems. It should be semi-formal, and does not include personal attacks like that. It's a safe place to fail, and should be maintained as such, lest the productivity advantages be lost.
We all make mistakes. I'm a Sr. Dev & Tech Lead and just last week I had an obvious error that a Jr dev caught. It's no big deal.
It can be easy to dwell on this, and think about over and over again. ADHD folks tend to have a stronger sense of justice, which means we are more sensitive to being "wronged", and it will bother us for longer. All I can say is try to not let it bother you as much, it was unprofessional to say that, and minute mistakes are the norm not the exception.