"Outing" someone can create a threatening and dangerous situation and crosses the line to harassment, which is against the law. 62% of trans students experience "cyberbullying" or online harassment.
It's never okay for trans people to be treated with scorn or ridicule. Challenge sexual violence or transphobia as soon as it comes up online or in person.
There's always more than one option for a bystander. Take a stand safely and do something that you feel comfortable with. You could: