A Casper man was sentenced Friday to a three-year term of probation for endangering a child with methamphetamine.

Natrona County District Court Judge Catherine Wilking sentenced Joseph Christopher Hubbard to probation instead of a potential two- to four-year prison term.

Assistant District Attorney Trevor Schenk and Hubbard's defense attorney Tim Cotton said they agreed with the terms of the agreement.

But Wilking cautioned Hubbard to adhere to the terms of probation or else he will serve the prison term as part of his plea agreement. Those terms include successfully completing probation, not using alcohol or controlled substances unless prescribed, not breaking any laws, being employed or in school, submitting to drug and alcohol testing, and participating in a substance abuse treatment program.

Hubbard had been free on bond.

The case started April 4 when Casper police officers arrived at Hubbard's apartment for a report of a family fight. A woman at the scene reportedly told police Hubbard had syringes and methamphetamine in the apartment, according to court records.

She said a child had been inside the apartment with Hubbard while he was allegedly using methamphetamine.

As officers approached the apartment, the woman who called police handed them a black binocular case with two syringes sticking out.

The woman then handed officers a plastic bag containing needles, with several used needles reportedly atop the plastic bag. One of the needles contained a "reddish tinted liquid."

The woman reportedly told officers Hubbard was high on meth.

She said she had recently arrived at the apartment to find the front door unlocked. She entered to find the child in his bedroom and reportedly saw Hubbard in the main bedroom with a needle in his arm, about to "shoot up."

She knew it was meth because "that was what he does." The Wyoming Department of Family Services was presently involved in an open case because of drug use, according to court documents.

After the woman arrived, the child reportedly went to the main apartment office and told the property manager "he was scared." They called 911.

The woman said she told Hubbard she was sick of his habit before retrieving a box of drug paraphernalia, intending to call police.

The children were taken into protective custody.

Officers wrote in an affidavit that small plastic bags with methamphetamine were atop the toilet in the bathroom and were easily accessible to children.