A San Diego County public defender was in court Friday, not to defend a client, but to plead guilty to providing a firearm to a felon.