(Reuters) – SolarCity, which was acquired by Tesla Inc at the end of last year, slashed nearly 20 percent of its staff in 2016 as it sought to preserve cash amid slowing growth in the rooftop solar industry.

In a regulatory filing on Wednesday, SolarCity said it had 12,243 employees at the end of 2016, down 19.8 percent from the 15,273 it reported a year earlier.

The cuts affected workers in operations, installations, manufacturing, sales and marketing, according to the filings. The number of people in general and administrative jobs has also fallen since June of last year, the company said.

SolarCity had announced job cuts before being acquired by Tesla but did not say how many employees would be laid off. Earlier in the year, it eliminated 550 jobs in Nevada after the state scrapped a key solar incentive.

SolarCity officials were not immediately available for comment.

The contraction in its workforce marked a sharp reversal from the company’s explosive growth in previous years. In 2015, the number of SolarCity employees swelled by 68.7 percent.

SolarCity, founded by the first cousins of Tesla founder Elon Musk, rose rapidly to become the nation’s top rooftop solar installer thanks to innovative no-money-down financing schemes and a vast sales operation. The company at one time had bold ambitions of having 1 million customers by 2018, but began scaling back its plans at the end of 2015 as costs for funding that growth mounted and demand began to slow.

By the middle of 2016, SolarCity had agreed to be acquired by Tesla, which said last month it was cutting spending on solar advertising in part by preparing to sell rooftop systems in Tesla’s network of retail stores.

The company is also shifting to more cash sales of systems instead of leases in order to generate cash and deliver the cost savings it promised investors would come from the acquisition.

Also in the annual filing, SolarCity said sales and marketing expenses fell 3 percent in 2016, in part due to staff cuts and efforts to boost sales efficiency.

(Reporting by Nichola Groom; Editing by James Dalgleish)