      def to_representation(self, value):
          if not value:
              return None
  
          if self.use_url:
              if not getattr(value, 'url', None):
                  # If the file has not been saved it may not have a URL.
                  return None
              url = value.url
              request = self.context.get('request', None)
 
</s> remove         if self.format is None:
 </s> add         if output_format is None: </s> remove         humanized_format = humanize_datetime.date_formats(self.input_formats)
 </s> add         humanized_format = humanize_datetime.date_formats(input_formats) </s> remove         if self.format is None:
 </s> add         output_format = getattr(self, 'format', api_settings.TIME_FORMAT)

        if output_format is None:
        if use_url:
      def to_representation(self, value):
          if not value:
              return None
  
        if use_url:
              if not getattr(value, 'url', None):
                  # If the file has not been saved it may not have a URL.
                  return None
              url = value.url
              request = self.context.get('request', None)
keep keep keep keep replace keep keep keep keep keep
 Access settings lazily, not at module import 
rest_framework/fields.py