In Star Wars, the bad guys will zap your entire planet from the cosmos if they disagree with your political position. In real life, it turns out that social media is a far more effective weapon of mass destruction; a Death Star for the alt-right age.

News that Kelly Marie Tran, aka Rose in Rian Johnson’s Star Wars: The Last Jedi, had become the latest actor of colour to be forced off Instagram by rightwing trolls was shocking when it broke earlier this year. There followed much soul-searching, wondering if it was still OK to be a Star Wars fan when so many other so-called fans clearly held repugnant views on race and gender. Those of us who had considered the original trilogy to be the epitome of everything wonderful about mainstream Hollywood in the late 1970s and early 80s suddenly began to worry about the lack of black actors on screen and that gold bikini scene in Return of the Jedi. Had Star Wars always been for the bigots, and we missed it?

Now that we know much of the online venom aimed at The Last Jedi was deliberately fomented by politically motivated activists and Russian trolls, it is tempting to breathe a sigh of relief. Dressing up as Rose, Rey or Finn this Halloween, rather than Luke Skywalker, should not, after all, be interpreted as a signal that one is engaged in a race and gender war against white men. Yoda does not speak using backwards syntax because he is being used to subvert modern American English, and with it prevailing Anglo-Saxon culture. Wearing one’s hair in dual space buns or sporting a gold bikini, à la Carrie Fisher, should not reflect a willingness to submit to the patriarchy – though adding a slave chain might be taking it too far.

Universally popular ... John Boyega and Kelly Marie Tran in Star Wars: The Last Jedi. Photograph: Allstar/Lucasfilm/Walt Disney Pictures

Suddenly a strange backlash that seemed to have leapt into view without warning, like a TIE fighter screaming out of hyperspace with all guns blazing, can be explained as just another example of an ongoing psychological war against liberal western culture. The Last Jedi can be restored to its rightful place in the Star Wars pantheon, as a highly entertaining episode that, while lacking the starry-eyed sense of the epic that permeated the original trilogy, did nothing to damage the franchise’s position as Hollywood’s pre-eminent source of cosmic tomfoolery.

The sense of relief that we are not, after all, sharing our local multiplex with Steve Bannon’s acolytes should also be palpable. Researcher Morten Bay, in his academic paper Weaponizing The Haters, estimates that more than 50% of negative online comments about the film came from political activists and trolls, of which a significant proportion originated in Russia. Moreover, we can assume that many more social media users felt emboldened by the poisonous debate around Johnson’s film to spew forth their own vitriol into the ether.

Electing Trump, bringing on Brexit, ruining Star Wars … praise Yoda's hairy ears the Russians never got behind putting George Lucas back in charge

But why target Star Wars, a saga that (at least if we ignore the much-maligned Jar Jar Binks years) is about as close as it gets to being universally popular? Russia’s determination to create political discord, via its activities during the Brexit referendum and in the run-up to Trump’s election, has always been easily explainable in a Machiavellian sense. If your business is maintaining power despite a severe democratic deficit and a poor human rights record, it is better to point to rightwing populist governments in other, rival nations that are behaving in a similar manner. And the best way to foster such movements is to encourage the kind of socially, culturally and racially charged discontent that leads to them coming to power. If Darth Vader had come to rule the Earth, rather than the vast stretches of a galaxy far, far away, he would have spent his first few months on the planet trying to turn humanity’s leaders to the dark side, rather than chasing Luke Skywalker. If there are no good guys left, the bad guys win – on more than one level.

Trump, Brexit … destruction worthy of the First Order. Photograph: AP

To attack Star Wars somehow seems mealy-mouthed, even for Russian uber-trolls. But, in a bizarre way, Disney and Lucasfilm should take pride that they have created something so central to our sense of cultural contentment that subverting it felt like the best way to bring down western democracy.

Electing Trump, bringing on Brexit and (nearly) ruining Star Wars – these are achievements worthy of the First Order itself. Thank goodness the last of these tasks has been stymied, and praise Yoda’s hairy ears that the Russians never got behind the Change.org campaign to put George Lucas back in charge of the long-running space opera. We could have all been in serious trouble.