A Tennessee man who possessed the gun authorities say a toddler used to fatally shoot a 7-year-old has pleaded guilty to a federal charge.

U.S. Attorney Don Cochran says 27-year-old Anthony Patrick Sanders entered the plea Tuesday to being a convicted felon with a gun.

Cochran says Harmony Warfield was shot June 6 in a Nashville apartment where three other children, ages 14, 11 and 2, were present. Authorities have said the 14-year-old reported the 2-year-old was holding the gun before the 7-year-old was shot in the head.

The statement says Sanders left the loaded gun where the children could access it, and after the shooting took the gun and fled. He was indicted eight days later.

The plea agreement calls for Sanders to serve 10 years in prison.