AIRWAY HEIGHTS, Wash. – A man was arrested Thursday for communicating with a minor for immoral purposes.

An Airway Heights police officer was on an unrelated call at the Walmart on Hayford Road on Tuesday evening. According to court documents, an off-duty Spokane Police officer told him he was trying to find a man who he believed had tried to proposition a child for sex.

Court documents said the officer contacted the child’s mother who said she was shopping with her 10-year-old daughter when she sent her a few aisles over to grab some coffee creamer. She said her daughter was contacted by a man, later identified Daniel Hastings, according to court documents.

The officer then spoke to the daughter who said she and her mother were at the Dollar Tree before they went to Walmart. She said Hasting approached her at the Dollar Tree and told her that he liked her red shoes, court documents said. The mother said she heard Hastings say this to her daughter but did not think anything of it at the time.

Court documents said the second time Hastings approached the girl, he told her he liked her shoes again, and he bent down and whispered in her ear, “I want you to cut a d**k off.” The girl told the officer she did not know Hastings. Court documents said she was visibly frightened and upset.

The officer then obtained surveillance photos of the man. According to court documents, when the officer showed the girl his photo she said, “That’s him.”

The officer posted the surveillance photos on the Airway Heights Police Department Facebook page on Thursday to try to identify Hastings. Court documents said within a few hours multiple people recognized Hastings and contacted the officer with information.

Officials then made a six person line up for the girl to look at to identify the suspect. Court documents said the girl identified Hastings as the suspect again.

According to court documents, when the officer was heading to the little girl’s home, Hastings called her. The officer said Hastings told him he saw his picture on Facebook and could not remember anything. Court documents said he would come speak with her at the police department and since he saw his picture on Facebook, he wanted to talk to a lawyer.

Court documents said Hastings was a registered sex offender and had previously been convicted of communicating with a minor for immoral purposes.

The officer then went to Hastings home and arrested him for communicating with a minor for immoral purposes. According to court documents, Hastings said he saw a young girl with red shoes at the Dollar Tree and told her he liked her shoes. He said he saw the same girl at Walmart but could not remember if he spoke with her. Hastings told the officer he had short term memory loss.

Court documents said Hastings asked if he could take his coat to jail with him and his mother came out to give him the coat. The officer said it was the same coat he was wearing in the Walmart surveillance video. The officer then advised his mother of the situation. According to court documents, she said Hastings believed that if he could cut off his genitalia he might stop having “urges.”

Hastings is being held in the Spokane County Jail on $25,000 bond.