Updated

A judge has dismissed illegal weapons charges against Fabolous that put the Brooklyn rapper behind bars for a night last October.

Fabolous was arrested Oct. 17 after he was treated for a minor gunshot wound following a wild night at Justin's, a Manhattan restaurant and club owned by Sean "Diddy" Combs.

A prosecutor said Thursday that authorities were unable to prove that Fabolous, 27, or three co-defendants were the owners of two loaded handguns found in a car in which they had ridden.

"He's more relieved than happy," the rapper's lawyer, Alberto Ebanks, said Thursday. "He should never have been here in the first place."

Trouble at the celebrity-studded nightspot began when someone snatched a $50,000 chain off the neck of then-Boston Celtics point guard Sebastian Telfair.

Gunfire later broke out in a parking lot near the restaurant. Fabolous was hit in the right thigh, then escaped the scene with three other men in a Dodge Magnum sport utility vehicle.

While he was being treated at a hospital, police searched the vehicle and found two handguns, a .40 caliber and .380 caliber semiautomatic. Neither gun was registered, and police said the serial number on the .380 had been scratched off.

"There were four guys in the car," Ebanks said. "My client jumped in the back seat of the car after he was shot. It was not the car he came to the club in."

Ebanks suggested in October that Telfair and Fabolous were victims of robbers who were targeting the club's high-profile clientele.

"These were people preying on celebrities," Ebanks said at the time, "and my client was obviously targeted because he is a high-profile celebrity and platinum-selling artist."

Detectives had Telfair view police lineups with suspects in the chain theft, but he failed to identify anyone.

Fabolous, who was born John Jackson, was in the courthouse Thursday, but stayed outside the courtroom after his lawyer told him the case was being dismissed.

His latest hit, "Make Me Better," is one of the top rap singles in the country.