Man released from 10-year sentence after court finds he was represented by a bogus lawyer