                      fk_field = obj._meta.get_field_by_name(accessor_name)[0].field.name
                      setattr(related, fk_field, obj)
                      self.save_object(related)
                  else:
                      setattr(obj, accessor_name, related)
              del(obj._related_data)
  
  
  class HyperlinkedModelSerializerOptions(ModelSerializerOptions):
      """
 
</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 </s> remove     target_source = models.OneToOneField(OneToOneTargetSource, related_name='source')


class OneToOneSourceSerializer(serializers.ModelSerializer):
    class Meta:
        model = OneToOneSource
        exclude = ('target_source', )

 </s> add     target = models.OneToOneField(OneToOneTarget, related_name='source')
                    # Reverse FK or reverse one-one
                      fk_field = obj._meta.get_field_by_name(accessor_name)[0].field.name
                      setattr(related, fk_field, obj)
                      self.save_object(related)
                  else:
                    # Reverse FK or reverse one-one
                      setattr(obj, accessor_name, related)
              del(obj._related_data)
  
  
  class HyperlinkedModelSerializerOptions(ModelSerializerOptions):
      """
keep keep keep add keep keep keep keep keep keep
 Cleanup one-one nested tests and implementation 
rest_framework/serializers.py