WordPress как на ладони
wordpress jino
событие не описано

pre_get_comments хук-событие . WP 3.1.0

Fires before comments are retrieved.

Использование

add_action( 'pre_get_comments', 'action_function_name_5058' );
function action_function_name_5058( $this ){
	// action...
}
$this(WP_Comment_Query)
Current instance of WP_Comment_Query (passed by reference).

Связи хука

Используется в: WP_Comment_Query::get_comments()

Остальные хуки из: WP_Comment_Query::get_comments():

Кусок кода с хуком

Фрагмент из: wp-includes/class-wp-comment-query.php WP 4.9
...
		global $wpdb;

		$this->parse_query();

		// Parse meta query
		$this->meta_query = new WP_Meta_Query();
		$this->meta_query->parse_query_vars( $this->query_vars );

		/**
		 * Fires before comments are retrieved.
		 *
		 * @since 3.1.0
		 *
		 * @param WP_Comment_Query $this Current instance of WP_Comment_Query (passed by reference).
		 */
		do_action_ref_array( 'pre_get_comments', array( &$this ) );

		// Reparse query vars, in case they were modified in a 'pre_get_comments' callback.
		$this->meta_query->parse_query_vars( $this->query_vars );
		if ( ! empty( $this->meta_query->queries ) ) {
			$this->meta_query_clauses = $this->meta_query->get_sql( 'comment', $wpdb->comments, 'comment_ID', $this );
		}

		/*
		 * Only use the args defined in the query_var_defaults to compute the key,
		 * but ignore 'fields', which does not affect query results.
		 */
		$_args = wp_array_slice_assoc( $this->query_vars, array_keys( $this->query_var_defaults ) );
		unset( $_args['fields'] );

		$key = md5( serialize( $_args ) );
...