So Fitzgerald sentenced Stewart, of Salford Street near Upland, to four to eight years in prison for possessing drugs with intent to deliver, for a lesser drug offense, and for possessing an instrument of a crime.
Stewart was acquitted of possessing drug paraphernalia and of conspiracy.
Privitera said Stewart has only himself to blame for his troubles.
On July 27, 1998, Stewart tripped up a silent alarm while he and his girlfriend were being robbed by a gang of thieves.
Police quickly arrived and arrested the robbers, then searched the home and found $25,000 worth of cocaine, and nine guns and $8,500 in cash, said Detective John McGrody.
Stewart, who denied living at the home, declined to say anything at the sentencing.
"He always carried a gun and a lot of money," the prosecutor said.
Stewart's former girlfriend and one of the robbers testified against him at his trial last month.
Holdup man DeVince Powell, 32, of 55th Street near Pennsgrove, said he planned the holdup because he knew Stewart was dealing drugs from his home.
Powell, who will get four to eight years for the robbery, said he had done business with Stewart before.
Charges against the girlfriend were dropped in exchange for her cooperation.