The deal gives US investors majority control, averting a nationwide TikTok ban