A cellphone expert overrode the lock function on an Apple iPhone to help Los Angeles police in a homicide investigation around the time U.S. authorities were battling the company to open other phones in criminal cases, court records showed on Thursday.

The successful hack of the iPhone 5s in the Los Angeles case is another sign U.S. authorities are turning to third-party contractors to unlock smartphones rather than relying on manufacturers like Apple Inc., which helped in the past. The third-party hacks have Apple racing to strengthen its encryption technology.

Los Angeles police gained access to the iPhone of April Jace, the wife of "The Shield" actor Michael Jace, who is accused of shooting her to death, at their home in May 2014.

Police investigators learned on March 18 that a forensic cellphone expert, whose identity was not released, could "override the locked iPhone function" on April Jace's phone to extract data, Detective Connie Zych wrote in a search warrant affidavit.

That was around the time the U.S. government was locked in a legal battle with Apple over requests the company unlock the iPhone 5c used by Rizwan Farook, one of the shooters in the San Bernardino killings.

Apple refused to bypass the encryption features on Farook's phone on grounds it could undermine security for all users. The company declined to comment on the Jace case.

The override of April Jace's iPhone 5s was less of a technical feat than the unlocking of Farook's iPhone 5c.

Jace's phone predated the iOS 8 operating system, which Apple introduced in fall 2014 with strengthened encryption methods. The contractor who unlocked Farook's iPhone 5c had to get past iOS 9, an operating system released in September 2015.

Apple helped authorities gain access to iPhones about 70 times before changing its position last year, court documents have shown.

It was unclear which OS was installed on Jace's iPhone. Her killing came after Apple released iOS 7, but before iOS 8.

In another high-profile case, the U.S. Department of Justice fought Apple in court seeking to force the company to assist authorities in accessing an iPhone 5S with iOS7 seized as evidence in a New York drug case.

Last month, the Department of Justice dropped the effort when it disclosed someone provided authorities the passcode to the device.

The hack of April Jace's iPhone appears to be related to an order in January by the judge to allow Michael Jace's defense team access to the phone.

Michael Jace's attorney in January argued in court the actor suspected his wife was having an affair and may have become enraged moments before the shooting, after seeing something on her iPhone, according to a report at the time from the New York Daily News.