Police officers swooped on a Blantyre house after a tip that there might be firearms stored there.
Hamilton Sheriff Court heard this week that they found a stun gun in a Lego box in the loft.
Jordan Moore, 24, was accused of possessing a prohibited weapon at his home in Welsh Drive in November 2018.
However, a jury found the charge not proven after he claimed he wasn't living there at the time and had no knowledge of the item.
Detective Constable Colin Sharp told the court he and five colleagues found the weapon after a search of the property.
It was wrapped in paper and tape, and was inside a Lego box.
Moore's mum, Irene Mathieson, was the only person in the house at the time and was arrested.
However, attention switched to her son after his fingerprints were found on the wrapping paper and tape.
Ms Mathieson said Moore was not living in the house at the time. He visited on occasions but was never in the loft.
Asked to explain his fingerprints being on the tape and paper, Moore said he had similar tape that he kept in a toolbox.
He told his lawyer, Jackson Bateman, that he believed he had been set up, but didn't know by whom.
Don't miss the latest headlines from around Lanarkshire. Sign up to our newsletters here.
And did you know Lanarkshire Live is on Facebook? Head on over and give us a like and share!