Individual employees publicly embarrassing the company (https://mobile.twitter.com/jweise/status/491788092710199297?...) or accidentally disrupting the network fabric and costing the company $X in missed revenue don't get fired for first offense. The way this was handled seems unusual, suggesting either there's a piece of the puzzle we internet pundits aren't holding or Google has changed its tolerance policy for honest mistakes.
If someone deliberately goes around those checks to push something anyway then it could be a fire-able offense.
She might be naive enough to believe that this was actually protected concerted activity, but I don't think so. I'm not sure I think firing her was the right play, but I also don't have all the information. I will say that I don't think this outcome should surprise her. It should definitely been one of the likely outcomes she modeled when deciding to submit that code.
So if her goal was to cause disruption at Google, it sounds like management just gave her a major assist. Like a Falcon Heavy's worth of assist.
Also, FWIW, this may provide some interesting reading: https://www.hg.org/legal-articles/are-employers-required-to-...