An Aberdeen drug dealer was caught when police found more than £1,000 of cannabis in his house.
Anthony Quantrell, 26, was at his city home on October 26 last year when officers executed a search warrant, Aberdeen Sheriff Court heard.
Depute fiscal John Richardson said officers found a small tub containing cannabis with a nominal value – and three other bags totalling £1,050.
Quantrell, whose address was given in court as Castleton Park, Aberdeen, admitted being concerned in the supply of a Class B drug.
Sheriff Ian Wallace ordered Quantrell to stick to the terms of a 12-month community payback order, to carry out 180 hours of unpaid work and to stay home from 7pm to 7am daily for four-and-a-half months as part of a restriction of liberty order.