A new leaked warranty guide for Apple iPhones shows how the company determines which iPhones are eligible for repair under warranty. Conditions are outlined for in-warranty repair, out-of-warranty repair, and devices categorized as “ineligible” due to damage or unauthorized modification. The 22-page guide is dated March 3, 2017 and was leaked recently to Dropbox, reports Business Insider. Called the “Visual/Mechanical Inspection Guide” (VMI) the document covers the iPhone 6, 6 Plus, 6S, 6S Plus, 7, and 7 Plus.

The types of damage that Apple covers under its warranty service includes debris under display glass or pixel anomaly, a misalignment of the FaceTime camera foam, or a single hairline crack to the front glass without an impact point. The VMI notes that devices with these types of impairments are covered regardless of any accidental or liquid damage.

Other damage, including LCD fractures, damage due to laser contact with the camera, extreme abrasion or puncture holes, multiple cracks in the glass, and damaged connectors are eligible for out-of-warranty service. Apple however, deems an iPhone ineligible for service if it shows intentional tampering or damage, is a disassembled unit or missing parts, contains non-Apple batteries, or is damaged “catastrophically.” Apple does note however, that AppleCare+ customers may be covered for catastrophic damage. AppleCare+’s hardware coverage does cover up to two incidents of accidental damage — with a fee of $29 for screen damage, or $99 for any other damage.

There is also a section on water damage and what to do if Apple’s liquid contact indicator (LCI) is triggered. Technicians are advised to pull apart the phone and check the indicator (which turns red when exposed to water) if a user disputes water damage. The document also shows that Apple doesn’t cover cosmetic damage to phones like chipping, dents, scratches, and scuff marks.

One Apple technician told Business Insider there was a similar warranty document for all of the company’s products, which are “used more for the physical inspection and how to determine cost for damage.” Another technician (also known as Geniuses) noted that the VMIs aren’t often used unless there’s an “oddball issue.”

"There are always those one-off issues that the phone is technically not covered under warranty but we swap the phone anyways under warranty," another Genius worker said.