Crash prevention: Try checking that an index path is valid.