A convicted sex offender who almost had another man take the fall for him is now serving a 30-year sentence for grabbing a 15-year-old girl off the street and raping her twice at gunpoint on the same night in two north Minneapolis alleys.

Harold T. Davis, 35, was sentenced in Hennepin County District Court after pleading guilty to first-degree criminal sexual conduct in connection with the back-to-back assaults late at night.

With credit for time he’s been in jail since his arrest in January, Davis will serve about 19½ years of his sentence in prison and then the remainder on supervised release for the rest of his life.

DNA test results exonerated the man who had been jailed for nearly two months in the attacks. Police initially arrested Charles E. Stevenson, 35, on Nov. 9 at his home in Minnetonka, and he was subsequently charged. His arrest was based on the girl identifying Stevenson.

Davis was convicted in 2008 in Hennepin County of second-degree criminal sexual conduct. He was sentenced to a 7½-year term and was under intensive supervised release at the time of the attacks.

While authorities got the wrong man, the details about the attack on the girl remain unchanged. The teen said she was walking to a friend’s house at about 1:15 a.m. and noticed a man she didn’t know was following her. Moments later, he grabbed her and pressed the gun’s barrel to her head.

He took her to an alley near 29th and Irving avenues, and forced her to have intercourse and give him oral sex. Davis then walked her to an alley roughly three-fourths of a mile to the west and raped her again.