def unwrap(self, value, fields=None, session=None):
        ''' If ``autoload`` is False, return a DBRef object.  Otherwise load
            the object.
        '''
        self.validate_unwrap(value)
        value.type = self.type
        return value
def unwrap ( self , value , fields = None , session = None ) : self . validate_unwrap ( value ) value . type = self . type return value
If ``autoload`` is False, return a DBRef object.  Otherwise load
            the object.