Chinese real estate giant Evergrande has sold its entire remaining stake in the film and TV streaming company HengTen Networks Group for $273 million, part of efforts to avoid defaulting on its massive debts.

The world’s most indebted developer, some $300 billion in the red, is struggling to meet interest payments on its loans, and has been selling off shares to raise funds.

At the beginning of the year, Evergrande owned a majority stake in Netflix-like HengTen. In July, it sold a 7% stake to Chinese tech giant Tencent for around $266 million. Last week, it sold a further 5.7% stake for about $145 million, the BBC said. HengTen’s name is a portmanteau made up of the first characters for Chinese names of Evergrande and Tencent.

Evergrande sold its remaining stake of HengTen to Allied Resources Investment Holdings at about a 24% discount to its Wednesday closing price. The company said that it estimates a loss of about $1 billion will be incurred in the transaction, which represents about 18% of HengTen’s issued shares.

The deal went through just a day before the firm was hit Friday with $148 million in overdue interest payments, according to the BBC. The company must raise $366 million by the end of the year to take care of interest payments on its debt.

Shares in Evergrande dropped around 2.5% on Thursday, while HengTen shares rose more than 23%.

Streaming company Hengten owns the membership-based video platform and app Pumpkin Film, which had 42 million registered users and 12 million paying users as of the end of March. In January, it also acquired Ruyi Pictures, a top film and TV production house that was a major producer of February’s Chinese New Year surprise hit “Hi, Mom,” which grossed $821 million to become the top-earning film by a female director in China.

Established in 2006, Ruyi Pictures has also backed popular TV series such as “Langya Bang,” “All Quiet in Peking,” “The Legend of Mi Yue” and “Eternal Love,” as well as films including 2018’s “Animal World” and “A Little Red Flower” starring Jackson Yee and Liu Haocun.