On Thursday, May 10, 2018, Fox canceled the five-season-old cop comedy Brooklyn Nine-Nine, to the consternation of the internet at large. Despite the show’s soft ratings, its large, talented ensemble cast, rapid-fire sense of humor, and commitment to subverting storytelling tropes in a more progressive manner had made the show a favorite of online TV fans.

The next morning, Fox revived Last Man Standing, a Tim Allen vehicle about a conservative dad who frequently argues with his more liberal offspring. The show had been canceled by ABC in the spring of 2017, and though the network had plenty of business reasons to cancel the show, Allen had spun it as the silencing of a proud Trump supporter in the year between cancellation and revival. Progressive TV fan Twitter wept.

Then a few hours after that, NBC picked up Brooklyn Nine-Nine for a sixth season, to much joy and merriment.

In many circles, this whole saga has been spun as a fundamentally political one: Fox (a corporate sibling of Fox News, after all) was embracing white, conservative voices, while NBC (a corporate sibling of MSNBC) was embracing more diverse, progressive voices. But that’s not really what’s happening here.

In fact, NBC and Fox “saving” Brooklyn and Last Man respectively are the same story told two ways, and they underline the realities of TV renewals and cancellations in 2018, when simply having bad ratings doesn’t mean you’re headed for the scrap heap and when it’s harder than ever to tell what a hit show is.

How two CBS sitcoms you probably don’t watch explain this even better than Brooklyn Nine-Nine and Last Man Standing

It used to be that cancellations and renewals were mostly simple business. Shows with good ratings were renewed; shows with bad ratings were canceled. There were exceptions here and there. A show with “good” ratings could be canceled if it lost too many viewers from a more highly rated lead-in, and another show with “bad” ratings could be renewed if it held its own in a tough time slot. But for the most part, Nielsen was king.

In the past 10 years, however, that has changed more rapidly with every TV season. Now, it’s important to understand a whole bunch of behind-the-scenes information before you know whether your favorite show with weak ratings is a cinch to come back or probably done for. And the most important question to ask is one that isn’t always easy to answer: Who owns the show? Who stands to make the most money from its continued existence?

Consider the CBS sitcoms Kevin Can Wait and Man With a Plan. Both shows launched in the fall of 2016 as part of the network’s storied Monday night sitcom lineup. Both boasted stars of old hit sitcoms as their leads — Kevin James was the Kevin who could wait, while Matt LeBlanc was the man who had a plan. Kevin boasted higher viewership than Man both in total viewers and among the younger viewers advertisers most care about, though only narrowly so. But when it came time to renew either show, Man With a Plan survived to the 2018-’19 TV season, while Kevin Can Wait was canceled.

You can try to explain this in a number of ways. Kevin Can Wait saw its audience tumble precipitously from its first season, when it was much more highly rated, while Man With a Plan’s second season decline was milder. Or maybe CBS just never thought Kevin worked after the ill-fated decision to kill off the title character’s wife between seasons one and two.

But the simplest answer is also the most likely correct one: Man With a Plan was produced by CBS Television Studios, while Kevin Can Wait was produced by Sony Television. And while CBS the network and CBS TV are two different companies — one a network and the other a studio that actually makes TV shows — as you can probably guess, they’re owned by the same corporation (the CBS Corporation). Sony TV, on the other hand, is owned by a completely different corporation. (Would you believe it’s the Sony Corporation?)

Here’s the thing about how TV networks make money: Technically, they only collect ad revenue from the programs they air. (There are occasional exceptions to this rule, but it’s generally true.) So CBS the network pays what’s called a “license fee” to “rent” these programs from CBS TV and Sony TV for a certain number of airings. It then collects revenue from advertisers, who pay to place spots in those airings. (You can read a lot more about this here.)

CBS TV and Sony TV, thus, operate at a loss initially, as the license fee probably won’t be enough to cover the production of the shows they’ve made. But if they can produce enough episodes of those shows, they can make more and more money from them by selling them in packages to cable networks, local syndication, international broadcasters, streaming outlets, and others.

Hopefully you can see where this is going: Because CBS the network and CBS TV are owned by the same corporate parent, the corporate parent gets to collect ad revenue from airing Man With a Plan as well as all eventual revenues from other packages and deals. Thus, it collects both the short-term and long-term revenue, and the show becomes more valuable to the network as a whole if it can run for more seasons (generally between four and six).

Thus, more and more cancellations and renewals are driven less by ratings and more by other business concerns, as the corporations that own these programs try to maximize the revenue they make from them.

As TV ratings decline, this divide between shows owned by network-affiliated studios and shows not owned by them will only grow

If this whole system seems a little biased against studios that aren’t owned by a corporation that also owns a TV network, well, you’re right about that. But studios like Sony TV or Warner Bros. TV continue to make new shows every year, and their best defense is always that the show turning into a big hit.

The Good Doctor, for instance, is a Sony show that airs on ABC (which is owned by Disney), but it’s such a big success that ABC wouldn’t dream of canceling it. It’s happy to have that short-term ad revenue. The Big Bang Theory, meanwhile, is an aging monster hit from Warner Bros. that airs on CBS, which would be very happy to see the show continue past its upcoming 12th season (the last it’s contracted for under its current deal).

This extends to other shows as well. Fox TV produces big hit shows for networks other than its own, like This Is Us for NBC and Modern Family for ABC (though if the Fox-Disney merger is approved, Modern Family will become a corporate sibling of ABC). ABC TV produces Criminal Minds for CBS. And so on. Sometimes, the best chance a show has at a long life is going to another network: Criminal Minds probably would have been canceled quickly at ABC, which doesn’t have a reputation for dark crime procedurals, but on CBS, it’s run for 14 seasons.

The same was true of the NBCUniversal production Brooklyn Nine-Nine, which Fox bid heavily on when it launched in 2013, especially since the network was better at launching ensemble comedies (like its then-hit New Girl) than NBC was at the time. And Fox TV sold Last Man Standing to ABC because ABC was known for supporting family comedies — and was also the TV home of Tim Allen’s old show Home Improvement. The story of these shows’ cancellations and renewals isn’t really a political one so much as it’s a story of two giant corporations trying to maximize revenue from two aging but valuable assets by making them run as long as possible.

If “airing a show on a TV network” feels like kind of a weird middleman step when it might be more efficient for studios to just make shows and release them directly to the public, well, that’s probably the future we’re headed toward, as the streaming world splinters into more and more niches. But for the time being, the big broadcast networks are still the best platform to gain attention for the sorts of shows that run for years on end.

And the cable and streaming platforms that can compete for that kind of attention tend to be few and far between. Yes, the occasional cable show like Game of Thrones or The Walking Dead can break through to megahit status, but it’s still much more likely that a Roseanne, a Good Doctor, or a This Is Us will rise on one of the big four broadcast networks, which have robust national presences thanks to their decaying but still valuable affiliate structures, which place local stations in major cities around the country.

But those days are rapidly coming to a close as ratings shrink or (in the case of streaming platforms) disappear altogether. And now that ratings have gotten to a point where they’re reasonably tiny for all but a few megahit shows, the divide between shows owned by studios affiliated with the networks they air on and shows owned by studios not affiliated with those networks is only going to grow.

Understanding why shows are or aren’t renewed used to be a fairly simple task. Now, increasingly, it involves looking beyond ratings to other information, which may not be as obvious on any given show’s surface. It’s tempting to grab hold of political rationales, especially in situations involving vocal stars like Tim Allen — but remember Kevin Can Wait and Man With a Plan. Usually, these things are just business.