The show has always thrived on unpredictability. Its creator, Elizabeth Meriwether, who’s long been refreshingly forthright about her creative process, quickly realized the strength of the supporting cast around Jess (Jake Johnson, Max Greenfield, Lamorne Morris, and Hannah Simone) and recalibrated New Girl as more of an ensemble comedy midway through its first season, a “hangout show” about a group of friends dealing with minor romantic and work-related flaps. Like Friends or How I Met Your Mother before it, New Girl’s shtick didn’t amount to much more than the age-old question, “Isn’t it hard to be a grownup?”

In season two, Meriwether hit the throttle on the burgeoning relationship between Jess and Nick (Johnson), the kind of will-they-won’t-they romance that other sitcoms would have dragged out for years. Suddenly, New Girl was less of a “hangout show” and more of a straight romantic comedy, as the boorish Nick struggled to keep up with Jess’s more precious interests, and the rest of the gang turned into a peanut gallery snarking at their ongoing affair. It worked better than it should have, partly because Deschanel and Johnson had tremendous chemistry, but it also unsurprisingly robbed the show of its dramatic tension.

So a year later Meriwether broke them up, an equally surprising move considering the popularity of the pairing. She admitted in an interview with Hitfix’s Alan Sepinwall that she’d struggled to mine interesting stories from a mostly stable relationship. “We couldn’t push the envelope as much as we wanted to. We were pulling our punches a little bit, trying to make it fun and believable that they were in love with each other,” she said. “It felt like we had to see them together in every episode, and that limited Nick from going off on his own and having stories.”

Which leads to Megan Fox. Since breaking up Nick and Jess, New Girl has leaned hard into its status quo as a wacky sitcom about 30-somethings struggling to master life. But it’s felt more and more strained as the cast has grown up (Deschanel is now 36, Johnson 37) while their characters’ development has remained arrested. So when Jess took a break from the show for a month (officially, she was sequestered in a hotel on jury duty) and was replaced by a new tenant, Reagan, the dramatic turnaround was remarkable.

Megan Fox is not, and has never been, a particularly funny actress. But Meriwether played to her strengths, writing Reagan as sardonic, distant, and perplexed by the bizarre closeness of the loft’s residents. She laid bare just how comfortable the New Girl gang had gotten in recent years, and Meriwether was clearly delighted to start pulling that situation apart. Reagan was like a new viewer tuning into the show, initially savaging it with withering criticism, but then slowly coming around to its charms.