          """
          m2m_data = {}
          related_data = {}
          meta = self.opts.model._meta
  
          # Reverse fk or one-to-one relations
          for (obj, model) in meta.get_all_related_objects_with_model():
              field_name = obj.field.related_query_name()
              if field_name in attrs:
 
</s> remove             if field_name in exclusions and not field.read_only:
 </s> add             if field_name in exclusions \
                and not field.read_only \
                and not isinstance(field, Serializer): </s> remove                 if related is None:
                    previous = getattr(obj, accessor_name, related)
                    if previous:
                        previous.delete()
                elif isinstance(related, models.Model):
 </s> add                 field = self.fields.get(accessor_name, None)
                if isinstance(field, Serializer):
                    # TODO: Following will be needed for reverse FK
                    # if field.many:
                    #     # Nested reverse fk relationship
                    #     for related_item in related:
                    #         fk_field = obj._meta.get_field_by_name(accessor_name)[0].field.name
                    #         setattr(related_item, fk_field, obj)
                    #         self.save_object(related_item)
                    # else:
                    # Nested reverse one-one relationship
        nested_forward_relations = {}
          """
          m2m_data = {}
          related_data = {}
        nested_forward_relations = {}
          meta = self.opts.model._meta
  
          # Reverse fk or one-to-one relations
          for (obj, model) in meta.get_all_related_objects_with_model():
              field_name = obj.field.related_query_name()
              if field_name in attrs:
keep keep add keep keep keep keep keep keep
 Cleanup one-one nested tests and implementation 
rest_framework/serializers.py