protected function prepareOriginalAttributes($entity) { if ($entity instanceof AttributesAccessInterface) { $entity->syncOriginalAttributes(); } return $entity; }