A man is in police custody thanks to his Facebook page.

Police charged Nathan Garza with capital murder. He's accused of killing Michael Hernandez during a home invasion back in December.

A friend of the victim wasn't able to identify the shooter during a lineup at first because the picture of Garza that was used was outdated, according to investigators.

Police then showed the friend a picture from Garza's Facebook page, in which she was able to identify him as the shooter.

Investigators believe the robbers were targeting money and narcotics inside the home.