LOUISVILLE, Ky. — A former Kentucky teacher has been sentenced to five years in prison for trying to receive sexually explicit images of a minor.

The U.S. attorney’s office in Louisville said 49-year-old Jeffrey McGaha of Russell Springs admitted trying to receive child pornography between 2012 and 2014, using a cellphone and social media applications.

U.S. District Judge Greg N. Stivers sentenced McGaha on Tuesday and ordered a 10-year period of supervised release. McGaha must register as a sex offender.

The Lexington Herald-Leader reported in April when McGaha pleaded guilty that he previously taught at an elementary school. Russell Springs police Chief Joseph M. Irvin told the newspaper that the minor in the case wasn’t McGaha’s student at the time but McGaha’s first contact with her was while teaching at another elementary school.