ASHEBORO, N.C. (AP) — A North Carolina high school graduate now has his diploma after a social media uproar over the Mexican flag he wore over his gown.

The school district initially withheld the diploma from 18-year-old Evan Lopez, saying that it violated the graduation dress code.

A video of the ceremony went viral, and Asheboro High School Principal Penny Crooks was subjected to threats.

The Lopez family sought a meeting to smooth things out, and WGHP reports that Lopez walked out with his diploma on Monday.

He's the first in his family to graduate from high school, and says he wore the flag out of pride for his Mexican roots.