A convicted drug dealer said he thought a vacuum-packed ball of cannabis found in his bedroom during a garda search was a "legal high".
Mark Dunne (43) said he had bought the €470 worth of "weed" for €80 in a shop because he did not realise it was illegal and it was "so cheap I couldn't say no".
Dublin District Court heard the shop was later investigated, raided and shut down.
Judge Grainne Malone found Dunne guilty of possession of the drug and having it for sale or supply.
She imposed a four-month suspended sentence.
Dunne, a father-of-two, had pleaded not guilty.
The prosecuting garda said he searched the house at Rafter's Avenue, Drimnagh, under a warrant on November 20, 2018 and found cannabis in a tightly-sealed, vacuum-packed plastic bag in the accused's bedroom.
Dunne took responsibility at the scene and said it was for personal use.
The garda initially believed it was a small amount because the ball was so tightly packed, but when opened it was obvious it was a larger quantity, 23.5g, valued at €470.
Dunne later told gardaí he bought "that weed" from a CBD shop.
He said he thought it was a legal high, it would take him a month to smoke it and he had not intended to sell or supply it to anyone else.
Asked if it was cannabis, he said: "Yeah, it could be."
He said that when he saw it in the shop, "it was so cheap I couldn't say no".
Defence solicitor Matthew Kenny said it was his client's "honest belief" that what he bought was not a controlled drug.
No tick list or weighing scales were found.
Judge Malone rejected the defence's argument.
She said Dunne's assertions went to his credibility and she could not accept them.
The accused suffered from his nerves and had relied on using cannabis, Mr Kenny said.