code: def moderate_model(ParentModel, publication_date_field=None, enable_comments_field=None):
      
      attrs = {
          'auto_close_field': publication_date_field,
          'auto_moderate_field': publication_date_field,
          'enable_field': enable_comments_field,
      }
      ModerationClass = type(ParentModel.__name__ + 'Moderator', (FluentCommentsModerator,), attrs)
      moderator.register(ParentModel, ModerationClass)
docs: Register a parent model (e.g. ``Blog`` or ``Article``) that should receive comment moderation.
  
      :param ParentModel: The parent model, e.g. a ``Blog`` or ``Article`` model.
      :param publication_date_field: The field name of a :class:`~django.db.models.DateTimeField` in the parent model which stores the publication date.
      :type publication_date_field: str
      :param enable_comments_field: The field name of a :class:`~django.db.models.BooleanField` in the parent model which stores the whether comments are enabled.
      :type enable_comments_field: str