A jobless man got jail for taking a knife onto an Alfreton street after being attacked.
Jonathan Alletson, 33, was later assaulted again in what was claimed to be a dispute about a missing phone, a court heard.
District Judge Leo Pyle told him: “You deliberately took a Stanley knife into a public place. There is no justification whatsoever for doing so.
“And in doing so, you put the whole populace at risk because that weapon could have been used.
“It was seen in a public place and led to violence being meted out on you.”
The judge said he was bound by the views of Chesterfield magistrates, who initially heard the case.
He added: “Whether you got jumped on before you went out, you took it out when you seemingly went to look for a mobile phone.”
An eight-week prison sentence was imposed on Alletson of Parks Avenue, South Wingfield. He admitted having a Stanley knife on King Street, Alfreton on May 8.
Asif Munir, mitigating, told Nottingham Magistrates’ Court: “He made an unfortunate decision to arm himself to recover his phone after being assaulted.
“No knife was seen in public and he never brandished the knife. It was never in his hand.”
Since his last court appearance, Alletson had fallen from a window and broke his left heel. He was treated at King’s Mill Hospital in Sutton in Ashfield.
That left him needing a wheelchair and the case had to be switched to the Nottingham court, which has special facilities.
Christine Ofosu-Ampadu, prosecuting, applied for the destruction of the knife and this was granted.
Alletson must pay a government surcharge of £115.