---
title: didTurnIntoFault()
framework: coredata
role: symbol
role_heading: Instance Method
path: coredata/nsmanagedobject/didturnintofault()
---

# didTurnIntoFault()

Provides an opportunity to add code into the life cycle of the managed object after converting it to a fault.

## Declaration

```swift
func didTurnIntoFault()
```

## Discussion

Discussion You use this method to clear out custom data caches—transient values declared as entity properties are typically already cleared out by the time this method is invoked (see, for example, refresh(_:mergeChanges:)).

## See Also

### Managing Change Events

- [contextShouldIgnoreUnmodeledPropertyChanges](coredata/nsmanagedobject/contextshouldignoreunmodeledpropertychanges.md)
- [awakeFromFetch()](coredata/nsmanagedobject/awakefromfetch().md)
- [awakeFromInsert()](coredata/nsmanagedobject/awakefrominsert().md)
- [awake(fromSnapshotEvents:)](coredata/nsmanagedobject/awake(fromsnapshotevents:).md)
- [changedValues()](coredata/nsmanagedobject/changedvalues().md)
- [changedValuesForCurrentEvent()](coredata/nsmanagedobject/changedvaluesforcurrentevent().md)
- [committedValues(forKeys:)](coredata/nsmanagedobject/committedvalues(forkeys:).md)
- [prepareForDeletion()](coredata/nsmanagedobject/preparefordeletion().md)
- [willSave()](coredata/nsmanagedobject/willsave().md)
- [didSave()](coredata/nsmanagedobject/didsave().md)
- [willTurnIntoFault()](coredata/nsmanagedobject/willturnintofault().md)
- [fetchRequest()](coredata/nsmanagedobject/fetchrequest().md)
