code: def format(self, record):
          
          if not hasattr(record, "type"):
              record.type = "   "
          return self._formatter.format(record)
docs: Format record with formatter.
  
          :param record: Record to format
          :return: Formatted record