The key is to not apologize and to have you career be semi-insulated from such a cancelling, in whatever form that takes (whether it's being self-employed in a way where a boycott doesn't hurt you too much, or working for someone that agrees with whatever it is you're saying and will stand by you, or just being independently wealthy).