A man agreed to store more than £300,000 of cocaine at his home after being made redundant.
Cameron O’Byrne lost his job as a telecommunications worker before turning to drink and drugs.
The 27-year-old, who reportedly had never been in trouble before, ended up in debt to local dealers.
In a bid to wipe out what was owed, he allowed the criminals to hide £338,680 of high-purity cocaine at his home in Coatbridge, North Lanarkshire, on May 14, 2020.
However, the haul was found during a police raid before O’Byrne was arrested days later.
On Tuesday at the High Court in Glasgow, O’Byrne was jailed for three years and four months after pleading guilty to being concerned in the supply of cocaine.
Prosecutor John Keenan told the hearing how the drugs were found in two rucksacks.
The cocaine had an average purity of 70%.
O’Byrne could not be traced for two days until he eventually handed himself into a local police station.
Billy Lavelle, defending, said: “This is the first time he has been in trouble and what a way to do it.
“Two years ago he lost his job – he was with a telecommunications company.
“He took redundancy and could not get a job to replace that. He was also going through difficulties in the family and he turned to alcohol for solace.
“He ended up taking drugs and, from there, it was a downward spiral.”
Mr Lavelle said O’Byrne’s “decent” family “were in shock” at his involvement in crime.
Lord Clark told O’Byrne the sentence would have been five years, but for the guilty plea.