code: def format(self, record) -> str:
          
          msg = dict(self.formatter_fields_for_record(record))
          if record.flatten and isinstance(record.msg, dict):
              msg.update(record.msg)
          else:
              msg[MSG_FIELDNAME] = record.msg
  
          if record.extra:
              msg.update(record.extra)
          if record.exc_info:
              msg["exc_info"] = record.exc_info
          if record.exc_text:
              msg["exc_text"] = record.exc_text
  
          return self.serializer(
              msg, default=self._default_handler, **record.serializer_kwargs
          )
docs: :type record: aiologger.loggers.json.LogRecord