Skip to content

Conversation

@Vedant-Gandhi
Copy link
Contributor

@Vedant-Gandhi Vedant-Gandhi commented Oct 16, 2025

Changes Made

  • Update the plugin name from Nginx Helper to EasyEngine Cache Helper for Nginx & Cloudflare (formerly Nginx Helper)
  • Add proper domain for i18n strings

@Vedant-Gandhi Vedant-Gandhi marked this pull request as ready for review December 17, 2025 08:57
sarthak-19
sarthak-19 previously approved these changes Dec 17, 2025
Copy link

@sarthak-19 sarthak-19 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor suggestion, rest LGTM !

'kind' => 'zone',
'phase' => 'http_request_cache_settings',
'description' => 'Set\'s the edge cache rules by Nginx-Helper Cache Manager.',
'description' => 'Set\'s the edge cache rules by Nginx-Helper Cache Helper.',

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be renamed from Nginx-Helper Cache Helper to EasyEngine Cache Helper ?

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR rebrands the plugin from "Nginx Helper" to "EasyEngine Cache Helper for Nginx & Cloudflare (formerly Nginx Helper)" as part of a broader rebranding initiative. The changes include namespace updates, option name changes, text domain corrections for i18n, and rebranding of links and assets to align with EasyEngine.

Key Changes:

  • Namespace changed from EasyCache to EECacheHelper across all PHP class files
  • WordPress option names updated from easycache_cf_settings to easyengine_cache_manager_cf_settings
  • Text domain updated from 'easycache' to 'nginx-helper' for all translatable strings
  • Updated branding assets including icons and external links
  • Removed Support tab and updated navigation structure

Reviewed changes

Copilot reviewed 16 out of 22 changed files in this pull request and generated 10 comments.

Show a summary per file
File Description
nginx-helper.php Updated plugin header with new name and description, updated WP-CLI command namespace
utils/autoloader.php Changed autoloader namespace check from EasyCache to EECacheHelper
includes/class-nginx-helper.php Updated namespace imports and option name in Cloudflare header handling
includes/class-cloudflare-tag-emitter.php Updated namespace and package documentation
includes/class-cloudflare-purger.php Updated namespace and use statements
includes/class-cloudflare-client.php Updated namespace and ruleset descriptions for Cloudflare
includes/class-cli.php Updated namespace for WP-CLI commands
admin/class-nginx-helper-admin.php Updated option names, constant names, menu titles, text domains, feed URLs, and cache timestamp message
admin/partials/nginx-helper-admin-display.php Updated page title and removed Support tab, renamed Cloudflare options file reference
admin/partials/nginx-helper-sidebar-display.php Updated external links from rtCamp to EasyEngine
admin/partials/easyengine-cache-manager-cloudflare-options.php Updated all form field names and option names for Cloudflare settings
admin/partials/nginx-helper-support-options.php Removed entire support options file
admin/css/nginx-helper-admin.css Updated icon reference and added background-size property
admin/icons/icon-64x64.png Added new 64x64 icon for rebranded plugin
composer.json Updated keyword from "easycache" to "easyengine cache helper"
readme.txt Updated plugin name, description, screenshot captions, and removed trailing whitespace
README.md Updated plugin name, description, added Cloudflare FAQ section, and screenshot references
wpassets/icon-256x256.png Added new WordPress.org plugin directory icon
wpassets/icon-128x128.png Added new WordPress.org plugin directory icon

Critical Issues Found:

  • Backward Compatibility: Option names and constant names have been changed without migration logic, which will cause existing users to lose their Cloudflare settings upon upgrade. Migration code should be added to preserve user configurations.
Comments suppressed due to low confidence (1)

admin/partials/easyengine-cache-manager-cloudflare-options.php:41

  • The option name has been changed from 'easycache_cf_settings' to 'easyengine_cache_manager_cf_settings' without any migration logic. This will cause existing users who have configured Cloudflare settings to lose their configuration after upgrading. You should add migration logic to copy settings from the old option name to the new one.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

<div class="wrap rt-nginx-wrapper">
<h2 class="rt_option_title">
<?php esc_html_e( 'Nginx Settings', 'nginx-helper' ); ?>
<?php esc_html_e( 'EasyEngine Cache Helper for Nginx & Cloudflare Settings', 'nginx-helper' ); ?>
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The title "EasyEngine Cache Helper for Nginx & Cloudflare Settings" is quite long for a settings page heading. Consider using a shorter version like "Cache Helper Settings" since users already know they're in the EasyEngine Cache Helper plugin.

Copilot uses AI. Check for mistakes.
background: url(../icons/nginx-icon-32x32.png) 0 6px no-repeat rgba(0, 0, 0, 0);
background: url(../icons/icon-64x64.png) 0 6px no-repeat rgba(0, 0, 0, 0);
padding-left: 40px;
background-size: 36px 36px;
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using a CSS pixel ratio media query to serve different icon sizes for high-DPI displays, or use an SVG icon for better scalability across all display densities.

Copilot uses AI. Check for mistakes.
$default_settings = $this->get_cloudflare_default_settings();

$stored_options = get_site_option( 'easycache_cf_settings', array() );
$stored_options = get_site_option( 'easyengine_cache_manager_cf_settings', array() );
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The option name has been changed from 'easycache_cf_settings' to 'easyengine_cache_manager_cf_settings' without any migration logic. This will cause existing users who have configured Cloudflare settings to lose their configuration after upgrading. You should add migration logic to copy settings from the old option name to the new one. Consider adding this in the handle_nginx_helper_upgrade method or in the activator.

Copilot uses AI. Check for mistakes.
Comment on lines +363 to +364
if ( defined( 'EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN' ) && !empty( EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN ) ) {
$stored_options['api_token'] = EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN;
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The constant name has been changed from 'EASYCACHE_CLOUDFLARE_API_TOKEN' to 'EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN'. This is a breaking change for users who have defined this constant in their wp-config.php. Consider supporting both the old and new constant names for backward compatibility, or document this breaking change clearly in upgrade notes.

Copilot uses AI. Check for mistakes.
"cloudflare-edge-cache",
"cache-tags",
"easycache"
"easyengine cache helper"
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The keyword "easyengine cache helper" contains a space, which may not be ideal for composer keywords. Consider using "easyengine-cache-helper" or "easyengine_cache_helper" instead, similar to the other keywords in the list which use hyphens.

Copilot uses AI. Check for mistakes.
'kind' => 'zone',
'phase' => 'http_request_cache_settings',
'description' => 'Set\'s the edge cache rules by Nginx-Helper Cache Manager.',
'description' => 'Set\'s the edge cache rules by EasyEngine Cache Helper.',
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The description mentions "Nginx-Helper Cache Helper" which is inconsistent. It should be "EasyEngine Cache Helper" to match the plugin's new name as stated in line 208.

Copilot uses AI. Check for mistakes.
array(
'general' => array(
'menu_title' => __( 'General', 'nginx-helper' ),
'menu_title' => __( 'Nginx', 'nginx-helper' ),
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tab menu title was changed from "General" to "Nginx". While this is more specific, consider that the tab contains general Nginx cache settings, not just Nginx-specific features. The name "General" might be clearer if the plugin handles both Nginx and Cloudflare settings, as "Nginx" might be confused with the separate Cloudflare tab.

Copilot uses AI. Check for mistakes.
Comment on lines +383 to +387
$stored_options = get_site_option( 'easyengine_cache_manager_cf_settings', array() );

$diff_options = wp_parse_args( $stored_options, $default_settings );

add_site_option( 'easycache_cf_settings', $diff_options );
add_site_option( 'easyengine_cache_manager_cf_settings', $diff_options );
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The option name has been changed from 'easycache_cf_settings' to 'easyengine_cache_manager_cf_settings' without any migration logic. This will cause existing users who have configured Cloudflare settings to lose their configuration after upgrading. You should add migration logic to copy settings from the old option name to the new one.

Copilot uses AI. Check for mistakes.
} else {
// Page is for an anonymous user and is cacheable.
$options = get_option( 'easycache_cf_settings' );
$options = get_option( 'easyengine_cache_manager_cf_settings' );
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The option name has been changed from 'easycache_cf_settings' to 'easyengine_cache_manager_cf_settings' without any migration logic. This will cause existing users who have configured Cloudflare settings to lose their configuration after upgrading. You should add migration logic to copy settings from the old option name to the new one.

Copilot uses AI. Check for mistakes.

if ( defined( 'EASYCACHE_CLOUDFLARE_API_TOKEN' ) && !empty( EASYCACHE_CLOUDFLARE_API_TOKEN ) ) {
$stored_options['api_token'] = EASYCACHE_CLOUDFLARE_API_TOKEN;
if ( defined( 'EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN' ) && !empty( EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN ) ) {
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing space after the ! operator. Should be "! empty" instead of "!empty" according to WordPress coding standards.

Copilot uses AI. Check for mistakes.
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 16 out of 22 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

'Cached using EasyEngine Cache Helper for Nginx & Cloudflare on ' . current_time( 'mysql' ) . '. ' .
'It took ' . get_num_queries() . ' queries executed in ' . timer_stop() . ' seconds.' .
"-->\n" .
'<!--Visit http://wordpress.org/extend/plugins/nginx-helper/faq/ for more details-->';
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The URL in the HTML comment uses the old WordPress plugin directory path 'http://wordpress.org/extend/plugins/nginx-helper/faq/' which may be outdated. The current WordPress plugin directory structure typically uses 'https://wordpress.org/plugins/nginx-helper/' (note the https and lack of 'extend' in the path). Consider updating this URL to match the current WordPress plugin directory structure.

Copilot uses AI. Check for mistakes.

if ( defined( 'EASYCACHE_CLOUDFLARE_API_TOKEN' ) && !empty( EASYCACHE_CLOUDFLARE_API_TOKEN ) ) {
$stored_options['api_token'] = EASYCACHE_CLOUDFLARE_API_TOKEN;
if ( defined( 'EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN' ) && !empty( EASYENGINE_CACHE_MANAGER_CLOUDFLARE_API_TOKEN ) ) {
Copy link

Copilot AI Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing space before the negation operator. The code uses '!empty' but WordPress coding standards require a space before the negation operator: '! empty'. This should be consistent with the spacing used elsewhere in the file (e.g., line 370 where '! empty' is correctly spaced).

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants