Friday’s announcement that e-commerce giant Amazon would buy the Whole Foods grocery chain had major implications for grocery delivery startup Instacart, which has pitched itself for years as a way for brick-and-mortar retailers to resist competition from Amazon. It seemed unlikely that Instacart would hold on to its agreement to deliver for Whole Foods, soon to be owned by its goliath rival.
Such a fate would be both a symbolic and material blow for Instacart since Whole Foods was its first national grocery partner in 2014. The two companies have worked closely together. Whole Foods even installed features in some stores intended to make Instacart shoppers’ work faster and easier.
Get Data Sheet, Fortune’s technology newsletter.
But a person close to Instacart told Bloomberg that the startup thinks it can still hang on to its Whole Foods partnership. How? Bloomberg's source says the deal is contracted to last another four years. It reportedly makes up less than 10% of Instacart’s revenue, still a substantial sum.
Whole Foods has also invested an estimated $36 million in Instacart. (The startup raised roughly $700 million in total funding.) Whole Foods’ investment was reportedly made at Instacart’s 2014 valuation of $2 billion, rather than its more recent $3.4 billion valuation, meaning Amazon could see a nice return on investment for the stake should Instacart reach a liquidity event of some kind.
Not that Instacart is waiting around. Despite its likely new ownership equation—the deal hasn't yet closed—Instacart is doubling down on its anti-Amazon rhetoric. An Instacart representative told Bloomberg that the company’s mission is “more important than ever given Amazon just declared war on every supermarket and corner store in America.” Well then.
Instacart's combative stance is strategic. With a focus on "last mile" delivery of fresh foods, Instacart could certainly complement Amazon's existing services. But its stance could attract rival grocers to partner with Instacart in a broader bid to resist Whole Foods' new corporate resources.
The winner in either scenario? Amazon, of course.