Johnson, 19, is accused of contacting Keahey using using the mobile app MeetMe, and engaging in a conversation that turned sexual. Prosecutors say that Johnson invited Keahey to his home, then began to beat him.

Prosecutors allege Johnson bound Keahey’s wrists, placed him in the trunk of his car and drove him to a family friend’s home. They say he eventually drove the victim to an EMS station.

The investigation revealed that on the night of the incident, Johnson saved Keahey’s cell phone number using a gay slur as a contact name, and Johnson later stated that he was playing a prank on the victim because of his sexual orientation, again using a gay slur when referring to Keahey.

Keahey was hospitalized for 10 days with multiple skull and facial fractures.

Prosecutors agreed to drop the hate crime count against Johnson in exchange for the plea, and he will remain in custody pending his Nov. 17 sentencing.

Fewer than one case a year on average has been successfully prosecuted in Texas as a hate crime since the law was enacted in 2001.