The sound you might have heard yesterday was the ringing of cash registers, as last-minute bargain hunters piled into Walmart stores for “going out of business” sales. Items were marked down as much as 75 percent in some Walmart locations. Two weeks ago, the company announced 154 closures in the U.S. and another 115 globally, part of a continuing trend of sagging retail fortunes.

This has raised concerns that cities hollowed out by Walmart’s entry will now suffer again from its abandonment. “The new way that Walmart is ruining America’s small towns,” Money magazine grouses. Food deserts will rise in neighborhoods with no access to fresh meat or produce, the Associated Press warns. Thousands of job losses will have an undeniable impact.

Related: 11 Things That Will Cost More in 2016​​​​

Anytime a major employer and monopoly provider skips town, the adjustment period can be painful. But paradoxically, the disruption may represent a renewed opportunity to revitalize rural communities. That’s ultimately a good thing for the nation, and even the economy.

Here’s a list of Walmart’s 154 store closures. You’ll find a few in big urban metropolises — Chicago, Los Angeles, Houston, Denver. But for the most part, Walmart is leaving places like Luther, Oklahoma, or Walnut, Mississippi, or Coal Hill, Arkansas. The majority of the closures are “Walmart Express” stores, which are somewhat smaller than the Supercenters and typically serve small towns. The company couldn’t make their business model work with reduced foot traffic in smaller locales.

The general story of Walmart and rural America is well-understood. The company big-footed in with the promise of low prices, attracting low-income shoppers straining to cope with stagnant wages and larger fixed costs for housing and health care. Family-owned, non-big-box retail stores, typically clustered in the town center, struggled to compete. Walmart could squeeze its suppliers on prices by promising them volume sales; the mom-and-pop stores had no ability to impose market power. Over time, the presence of Walmart crushed Main Streets across the country, dislocating entire communities. These towns came to rely on Walmart as the largest employer and the source of an astonishing percentage of total tax revenue.

Related: Here's Why Millions of Americans Feel Like the Recession Never Ended

Some see these subsequent closures as akin to Walmart leaving the carcass by the side of the road after feasting on it. There’s no question that some communities will feel a burden in the immediate term, with residents having to drive long distances for decent food or medicine.

But getting Walmart out of the picture can also herald a “locally sourced” comeback. That’s the perspective in Winnsboro, South Carolina, population 3,500, and home to a big-box Supercenter closure. Those residents still require basic needs, and local grocers and merchants, once confined to the sidelines, might be lured back onto the field. “No one wanted to compete” with Walmart in Winnsboro, according to one commercial real estate agent. Now its departure gives the locals a chance.

Walmart’s closures stem from increased competition with Internet sales, a phenomenon that writer Matt Yglesias habitually calls The End of Retail. Online sales have indeed surged, but that may be less of an issue in rural areas where one-stop shopping on Main Street offers more convenience than waiting for shipping, or in low-income communities that may not be able to afford Amazon Prime or even the Internet service required to access it.

Related: Why Amazon Prime Is Such a Great Deal – for Amazon​

Moreover, if Walmart cannot make low supplier costs and global logistics work in these towns, it’s doubtful another big-box chain will make the attempt. The best solution, then, calls for local stores with smaller supply chains. That could provide a boost to manufacturers and distributors in and around the small towns, not just the returning groceries and department stores. Related to this, when Walmart dominates retail in one town, the money all flows to their corporate treasury in Bentonville, Arkansas. When a mom-and-pop store thrives, the money goes into their bank account and is more likely to get distributed within the community, creating a positive economic feedback loop.

There’s also the knock-on effect of bringing foot traffic back to Main Streets, rather than sending customers to big-box superstores off the Interstate, outside the city center. It can be mutually reinforcing, not just to local commerce but to local culture, to have residents visiting a central location of multiple stores to shop. The recent rise of independent bookstores suggests that people, as social creatures, might actually want to interact with others, and live in places with a unique identity. In this context, ditching the Walmart can actually build community.

I don’t want to paint too rosy a picture. Small businesses always face difficult challenges, from securing loans to establishing a customer base. And Walmart wouldn’t be closing stores nationwide if there wasn’t a general dampening of the retail space. It’s possible that some small towns just shift from Walmart to some other cut-rate dollar store chain, with the same woes in place.

Related: Why Half a Million People Will Lose Their Food Stamps This Year​

This is where states and even the federal government can be helpful. The Small Business Administration should identify “food desert” areas, with high poverty and little access to fresh food, and support lending to merchants that might bridge that divide. Grants to redevelop Main Streets could revive the local spirit and set this virtuous circle in motion.

What we shouldn’t do is beg for Walmart to stick around. Its presence not only decimated small towns all over the country, it did little for workers, who would have to hold charity food drives or sign up for federal assistance programs just to stay afloat. Monopoly providers like Walmart, despite their low prices, do far more damage to suppliers, workers and related businesses to be a positive force in communities. We should want to give small-town entrepreneurs the economic liberty to use their talents and skills, rather than shuttling them upward to an impersonal automaton.

Nobody wants to see cities left without a pharmacy or grocery store. But if it can lead to a viable future rather than just hanging on, Walmart’s closings could just be a blessing in disguise for small-town America.