A Towy Valley shop worker has been warned that “growing cannabis is just as bad as buying it” by magistrates.

Samuel Phillip John Mallam, of 41 Parc Pencrug in Llandeilo, appeared before Llanelli court to admitted possession of 229 grammes of the Class B drug.

The 21-year-old told police he had grown the drug in a bedroom cupboard to avoid having to go out and buy it from a dealer.

Officers valued the drugs found at the property at £400.

Ellie Morgan, prosecuting, described how a police patrol car travelling along the unclassified lane between Cwmifor and Taliaris at 6.20pm on July 7 spotted Mallam’s car parked in a lay-by.

Mallam and another man were in the vehicle.

As the officers approached, “Mallam was moving around in a furtive manner,” said Ms Morgan.

“It looked like he was trying to hide something.”

The vehicle “smelled strongly” of cannabis she said.

A search of the car revealed a cannabis grinder containing a small amount of the drug under the front passenger seat.

Mallam admitted the grinder was his.

A subsequent search of Mallam’s home address found a bag containing eight grammes of the drug on his laptop, another bag containing 200 grammes of cannabis in a bedroom cupboard.

Two more bags – containing a total of 20 grammes – were in a box in the bedroom.

Mallam said all the drugs belonged to him and he intended to smoke it.

Robin Reed, defending, told magistrates that the bag found in the cupboard contained buds and stalks and was being left to dry after being harvested.

“He decided he would grow cannabis to avoid having to buy it from dealers,” said Mr Reed.

“He grew one small plant in a cupboard at home.

“Once the plant had dried its weight would have reduced to around 40 grammes. That would have led to a total of around 69 grammes in his possession.”

Mr Reed said Mallam’s arrest had had “a profound effect” on him.

“He has used this as a wake-up call,” said Mr Reed. “He had stopped smoking cannabis.”

Magistrates granted Mallam a conditional discharge for 18 months and ordered he pay £85 costs and a £15 legal surcharge.

“Growing cannabis is just as bad as buying it,” Mallam was told. “It can seem less serious but it is not.”

The Guardian has been asked to point out that the address listed in court - 8 Caledfwlch in Cwmifor - was not Mallam's former home as previously stated.