versatileimagefield/serializers.py
def to_native(self, value):
        """For djangorestframework <=2.3.14"""
        context_request = None
        if self.context:
            context_request = self.context.get('request', None)
        return build_versatileimagefield_url_set(
            value,
            self.sizes,
            request=context_request
        )
def to_native(self, value):
        context_request = None
        if self.context:
            context_request = self.context.get('request', None)
        return build_versatileimagefield_url_set(
            value,
            self.sizes,
            request=context_request
        )
def to_native ( self , value ) : context_request = None if self . context : context_request = self . context . get ( 'request' , None ) return build_versatileimagefield_url_set ( value , self . sizes , request = context_request )
For djangorestframework <=2.3.14
For djangorestframework < = 2 . 3 . 14