Apple stock slipped on Monday after China threatened to cut iPhone sales if President-elect Donald Trump slaps it with the hefty tariffs he said he would impose while on the campaign trail. However, the iPhone maker’s shares were quick to bounce back on Tuesday. Analysts were quick to consider the ramifications for tech companies, including Apple, thanks to Trump’s surprise victory in the race for the White House.

Apple Inc. Stock Bounces Back After Concerns That Trump Won't Get Along With China

Apple stock, other tech stocks bounce back

In addition to Apple stock, investors were also dumping Facebook, Alphabet, Amazon and other technology companies and rotating into utilities and financial stocks in the wake of the election. The sectors are seen as being possible beneficiaries of Trump’s planned deregulation and increases in spending on the nation’s infrastructure.

Apple stock extended its post-election declines on Monday after a Sunday report from China’s state-run Global Times which warned that Beijing would retaliate if Trump follows through with his threat of a 45% tariff on Chinese imports. The Chinese media outlet’s op-ed piece declared that some orders previously allotted to Boeing would be diverted to Airbus, while U.S. car and iPhone sales in China would also fall and imports of corn and soybeans from the U.S. would be stopped.

On Tuesday, however, Apple stock rallied, climbing 1.32% to close the regular trading hours at $107.11—still lower than where the shares were trading before the election, but an increase, nonetheless.

What happens if China really cuts iPhone orders?

One thing investors must take into consideration is the fact that Apple was already struggling in China, so if iPhone orders continue falling, it won’t be entirely Trump’s fault. The company’s China revenue tumbled 30% in the September quarter, making the region far worse for Apple than the Americas, where sales slipped 7%. Chinese smartphone brands are much cheaper than the pricey iPhone, and sales of brands like Huawei and Xiaomi have been soaring in China.

Before the weekend op-ed piece from out of China, UBS analyst Steven Milunovich was already considering what Apple would have to do if it continues to struggle in China. In a research note dated Nov. 11, he set forth his estimates for how fast the company would need to grow its iPhone units in the rest of the world if China is still week in fiscal 2017.

How much of a risk from China?

Milunovich warns that iPhone unit growth in the double digits is possible in fiscal 2017, based on his demand model. He said his survey suggests that just 43% of those who bought an iPhone in fiscal 2015 intend to upgrade, and the number of new users may fall 10%.

He adds that China is the biggest wild card here, as Greater China is nearly 30% of iPhone sales, and about half of sales there are to new customers, which means that half of new customer adds are in China. He estimates that Apple will see a 5% decline in iPhone units in China in fiscal 2017, based on the recent weakness and his recent survey, which pointed to lower interest in the iPhone 7 than in previous models. He adds that his estimate is 18% lower than in fiscal 2015 when Apple added China Mobile.

According to the UBS analyst, if Apple’s iPhone units tick down 10% in China in fiscal 2017, then the units in the Rest of the World would have to grow 5% for unit sales to be flat with last year. However, he actually expects Rest of the World units to grow 10%, noting that they grew 13% in fiscal 2014 and 27% in fiscal 2015 before falling by about 5% in fiscal 2016.

Apple stock still a buy for fiscal 2018

Milunovich still sees Apple stock as a buy based on what next year’s tenth anniversary iPhone is expected to bring. He said consumers may be tempted to wait until next year’s iPhone because of all the major new features that are expected. He adds that if retention rates don’t fall, then fiscal 2018 might bring “a windfall of upgrades” for Apple.

The analyst notes that Apple stock is usually driven by whether or not the company beats estimates. He sees downside risk for the March and June quarters but adds that it might not matter for Apple stock if investors are extremely optimistic about fiscal 2018.