Apple's legal counsel gets to see this data, NOT Apple itself, and the data is under a protection order by the judge.
A third-party subpoena is a fairly common thing in business litigation; the court balances the power of that kind of discovery by strictly limiting who gets to have eyes on it (lawyers, not clients) and stacking up both enormous liability and penalties, both civil and criminal, for leaking or sharing that information beyond the legal counsel.
This is a pretty humdrum decision by the courts, it's just exciting to nerds because of the brand names involved.