A 22-year-old Derry man said he was 'glad he got caught' after he admitted possessing cannabis with intent to supply.
Emmet Devenney of Rinmore Drive in Derry admitted the charge which occurred on October 30 last year when he appeared at Derry Crown Court.
The court heard that police searched a flat Deveney was renting and when they arrived there were a number of people there and cannabis sitting on a tray in full view.
They searched the premises and found a sum of money and some scales and more cannabis.
The court heard that Devenney had co-operated with the police and had offered to tell them where the drugs where in the flat.
The prosecution also said that police examined a mobile phone and found messages that indicated drug dealing.
Two months previously Devenney had been fined in the Magistrate's Court for possessing cannabis.
A defence barrister told the court his client had received a 'positve' pre-sentence report. He said while it was not an excuse Devenney was only supplying a demand that was already there.
Judge Des Marinan said it was a 'difficult case' as supplying drugs was a 'terrible curse on society'. But he said Devenney had shown a very positive attitude.