A Salt Lake City, Utah, mother has been charged with wiretapping for secretly recording conversations between her ex-husband and children.

Teri Anne Smith, 37, placed a recording device in a diaper bag nine times when her children visited their father in 2012, reports Standard Examiner. A device was also found in one of her children’s coat pockets by the father.

Smith’s lawyer argued that it was legal for her to record the conversations as she thought her children were in danger from sexual abuse and federal and state laws give a parent that right under such a circumstance.

A request for the charges to be dropped was made in June.

“The state and the alleged victim disagree (with the defendant) concerning any claims of sexual abuse that was taking place,” Deputy Davis County Attorney Richard Larsen said.

No charges of abuse have been brought against the ex-husband.

In court, Larsen argued that if law enforcement personnel bugged someone’s home without their knowledge, “they’d be sued.”

The three counts of wiretapping or intercepting electronic communications, all third-degree felonies, will stand against Smith.

The wiretapping charges carry a possible jail time of five years or a fine of up to $5,000, reports The Daily Mail.

Smith is scheduled to return to court on Aug. 27.