A judge has described as "insanity" the decision to give bail to a Lancashire teenager who had admitted a spate of burglaries.
On his release from custody Peter Downey went on to commit another burglary at sheltered accommodation in Preston.
Downey had originally been arrested for a break-in at Hull Street in Ashton, Preston Crown Court heard.
He went on to confess to five others, all committed in a bid to raise money for a drug debt.
Judge Beverley Lunt was then told that Downey was granted bail.
She said: "Who on earth gave him bail? Insanity!"
Prosecutor Paul Cummings said that in August Downey entered the sheltered accommodation and stole cash and jewellery belonging to an elderly couple.
Downey, 19, of Maritime Way, Ashton, Preston, pleaded guilty to two burglaries and asked the court to take five others into consideration.
He was also in breach of a suspended sentence order.
Judge Lunt sent him into youth custody for a total of 23 months.
Jenny Ashworth, representing Downey, said his case had a tragic history.
She said: "His parents are both law abiding, decent individuals and barely recognise him as their son."
After a promising school record he obtained an apprenticeship but, next door to the garage, there was a crack cocaine den, she said.
He got to know those living there and experimented with the drug which quickly became, "all consuming", Miss Ashworth told the court.
She said Downey went on to build up a "significant drug debt" which led to threats against not only him, but also his mother's local business.
>> Vote in our latest web poll
The full article contains 277 words and appears in n/a newspaper.