July 20, 2022 | 5:46pm

Christine Baranski admitted she was “dissing” Elon Musk right as a photo of the actress glaring at the SpaceX founder was snapped at the 2022 Met Gala.

“The funny thing is I have no memory of turning back and glaring at him,” the “Good Fight” star told Entertainment Weekly on Wednesday.

She added, “I was actually dissing him as I was waiting in line to go to dinner.”

Baranski explained to the magazine that someone she was with pointed out Musk behind her and she responded, “I basically said [to my friend], ‘I don’t know how you feel about him, but why is he spending billions of dollars in space when he could be cleaning up the planet?’ I’m an environmentalist.”

Despite her disapproval towards Musk’s spending habits, Baranski, 70, did not mean to scowl at the TESLA CEO.

“I must have at some point turned back and looked, but I did not pose for that picture,” she explained.

Christine Baranski pictured at a red carpet event in New York.
Christine Baranski reveals what was happening when she glared at Elon Musk at the 2022 Met Gala.
Getty Images

Baranski also shared that reoccurring “Good Fight” and “Good Wife” character Neil Gross, a billionaire akin to Musk, will return for the show’s final season.

“I get to bash the billionaires a bit,” the “Mamma Mia” actress said. “I’ve added a few lines [to the script], and I actually will include Elon Musk in the final episode.”

Elon Musk at an event in New York.
Musk made headlines recently for secretly welcoming twins with one of his top executives.
WireImage

In the series, John Benjamin Hickey plays Gross, the founder of a billion-dollar search engine called Chumhum.

Musk made headlines recently after he secretly welcomed twins with one of his top executives at Neuralink, Shivon Zilis, in November 2021.

Musk has 10 children with several different women: Nevada Alexander, who died as an infant, 18-year-old twins Griffin and Vivian, 16-year-old triplets Kai, Saxon and Damian, 2-year-old son X AE A-XII, 4-month-old daughter Exa Dark Sideræl, and the twins he shares with Zilis whose names are unknown.

The richest man in the world was most recently linked to “Britney Ever After” actress Natasha Bassett, 27.