(CNN) A social media rivalry between two Dallas rappers escalated into a shooting that left a 9-year-old girl dead days before school started, police said.

East Dallas resident Brandoniya Bennet was struck by a bullet in the head Wednesday as she sat on a couch after getting her nails done for the first day of school, CNN affiliate KTVT reported.

The suspect, Tyrese Simmons, 19, turned himself in Thursday and faces a capital murder charge, Dallas Police said in a statement.

Simmons allegedly went to an apartment complex to confront a rival rapper after the two exchanged disparaging comments about one another on social media, according to authorities. The other person did not come out of his apartment, so Simmons circled around to the back, police said.

Then Simmons opened fire, shooting at the wrong apartment and fatally wounding Brandoniya, police said.

Read More