HEX
Server: Apache
System: Linux scp1.abinfocom.com 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User: confeduphaar (1010)
PHP: 8.1.33
Disabled: exec,passthru,shell_exec,system
Upload Files
File: /home/confeduphaar/www/wp-content/plugins/wp-rocket/inc/3rd-party/plugins/rating/wp-postratings.php
<?php

defined( 'ABSPATH' ) || exit;

if ( defined( 'WP_POSTRATINGS_VERSION' ) ) :
	/**
	 * Conflict with WP-PostRatings: Clear the cache when a post gets rated.
	 *
	 * @since 2.6.6
	 *
	 * @param int $user_id user ID.
	 * @param int $post_id post ID.
	 */
	function rocket_clear_cache_on_wp_postratings_rate( $user_id, $post_id ) {
		rocket_clean_post( $post_id );
	}
	add_action( 'rate_post', 'rocket_clear_cache_on_wp_postratings_rate', 10, 2 );
endif;